-
Notifications
You must be signed in to change notification settings - Fork 871
An error occurred while calling method 'ConfigureServices' on startup class #970
Comments
I believe your issue is related to (and fixed) in this code commit: This updated version has not been released yet. To get around the issue, you may want to copy the code in the corrected version into your own, custom UserStore as a temporary workaround. |
@ketrex So I need to copy the UserStore file: But how to register this UserStore in my Startup class? And will there be a release before 1.1 with this fix? |
@mdmoura
with
.AddEntityFrameworkStores() is just a helper method, if you dig into it, all it does is add the two stores to your service container. You can review it here |
Dupe of #855 |
Not sure what the problem is but I added the new UserStore to my code and named it CustomUserStore: And on Startup I added the following:
This compiles but when I run it I get the following error on Program/Main:
Any idea why this happens? |
@mdmoura, I'm afraid that's not enough for me to go on. Any chance you can throw your project in a github repo so I can take a look? That error indicates that your container does not contain all the necessary members to instantiate your custom UserStore. But without your code, it's hard to tell what the problem is. |
@ketrex I just added to a demo project to github: If you start the project with will get an error on Program/Main. Am I missing something? |
@ketrex Sorry for the delay. Thank you, that worked fine. |
With ASP.NET Core 1.1 I tried to use again:
But I get the errors:
Do we still need to use custom UserStore and RoleStore? |
On an ASP.NET Core 1.0.1 project I have the following context:
Where the entities are the following:
On Startup I have the following:
When I run "dotnet ef migrations add "FirstMigration" I get the following error:
Am I missing something or is this a bug with the new IdentityDbContext?
The text was updated successfully, but these errors were encountered: