-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Refactor MigrationsModelDiffer to use the database model. #20305
Conversation
d40c737
to
9eef47b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😍 It's so beautiful!
src/EFCore.Relational/Migrations/Internal/MigrationsModelDiffer.cs
Outdated
Show resolved
Hide resolved
?? typeMapping.ClrType).UnwrapNullableType(); | ||
|
||
columnOperation.ColumnType = property.GetConfiguredColumnType(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was some subtlety around GetConfiguredColumnType that I can't remember. But I probably wrote a test to cover it, so as long as no test fails... 😬
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that was from when we tried to avoid putting the store type in the snapshot
test/EFCore.Relational.Tests/Migrations/Internal/MigrationsModelDifferTest.cs
Show resolved
Hide resolved
test/EFCore.Relational.Tests/Migrations/Internal/MigrationsModelDifferTest.cs
Show resolved
Hide resolved
7a51371
to
20b4b8a
Compare
Change IMigrationsAnnotationProvider to use the database model and split a part to IRelationalAnnotationProvider Add IRelationalModel Add more shared objects validation Part of #2266
20b4b8a
to
3eec55e
Compare
@AndriySvyryd This is the PR that broke the error page, right? Do we need to document some of the breaking changes here? |
@ajcvickers The offending changes were in the signature of cc @bricelam |
@AndriySvyryd Not 100% convinced. It's not uncommon to get questions on model diffing. |
I've shown a lot of people how to call those over the years. We should at least document |
Change IMigrationsAnnotationProvider to use the database model and rename to IRelationalAnnotationProvider
Add IRelationalModel
Add more shared objects validation
Part of #2266