.NET Core + Openiddict InvalidCastException

感情迁移 提交于 2019-12-12 17:23:38

问题


I'm using openiddict on a .net core 1.1 project. So far i was able to login through /connect/token endpoint.

Suddenly, without any changes to the controller i get the following exception

InvalidCastException: Unable to cast object of type 'AspNet.Security.OpenIdConnect.Primitives.OpenIdConnectRequest' to type 'OpenIddict.OpenIddictOptions'.

Is there anyone else having the same issue?


回答1:


API changes have been introduced in ASOS 2.0.0-rc1-final that are incompatible with the exact OpenIddict version you're using. To fix that, remove the packages that start with AspNet.Security.OpenIdConnect from your .nuget\packages folder and restore your project when it's done.



来源:https://stackoverflow.com/questions/46714513/net-core-openiddict-invalidcastexception

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!