Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EF Core 7 - Remove Default Context constructor not working #1539

Closed
TimKras opened this issue Oct 10, 2022 · 7 comments
Closed

EF Core 7 - Remove Default Context constructor not working #1539

TimKras opened this issue Oct 10, 2022 · 7 comments
Labels
enhancement New feature or request reveng

Comments

@TimKras
Copy link

TimKras commented Oct 10, 2022

In EF Core 7, no default constructor is generated. Not sure if this is by design, but this options does nothing:
image

@ErikEJ
Copy link
Owner

ErikEJ commented Oct 11, 2022

It is by design, yes: dotnet/efcore#23515 (I you choose "no connection string")

@ErikEJ
Copy link
Owner

ErikEJ commented Oct 11, 2022

I have updated the label in the latest daily build:

Remove default DbContext constructor (EF Core 3 & 6) 

@ErikEJ ErikEJ closed this as completed Oct 11, 2022
@ErikEJ ErikEJ added enhancement New feature or request reveng labels Oct 11, 2022
@ErikEJ ErikEJ reopened this Nov 22, 2022
@ErikEJ
Copy link
Owner

ErikEJ commented Nov 22, 2022

Reopening - I was mixing thing up. This should also be implemented for EF Core 7

@ErikEJ
Copy link
Owner

ErikEJ commented Nov 22, 2022

@TimKras >>In EF Core 7, no default constructor is generated.

I see a default constructor!

@TimKras
Copy link
Author

TimKras commented Nov 22, 2022

@TimKras >>In EF Core 7, no default constructor is generated.

I see a default constructor!

I don't really understand?

@ErikEJ
Copy link
Owner

ErikEJ commented Nov 22, 2022

When running EF Core 7 reverse engineering a default constructor us being generated.

And for EF 7 the option above has no effect but it should

@ErikEJ ErikEJ changed the title EF Core 7 - No Default Context constructor EF Core 7 - Remove Default Context constructor not working Nov 29, 2022
@ErikEJ ErikEJ closed this as completed in daf4180 Nov 29, 2022
@ErikEJ
Copy link
Owner

ErikEJ commented Nov 29, 2022

@TimKras Fixed in latest daily build - sorry for the delay.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request reveng
Projects
None yet
Development

No branches or pull requests

2 participants