-
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
Add a prompt y/n #27079
Comments
And what would a reply of "n" result in? |
I agree that many people ignore the warnings. Entity Framework Core already faced the issue of warnings #14935 |
Cancel Migration |
As I understand this happening after a migration have been created, I suppose the warning just result of comparing old and new state. |
@nerd3717 Best practice for any generated migration is to review it to ensure that it's doing what you expect/want it to do. This is also the case for migrations that may cause data loss. The change might not actually cause data loss in any meaningful way to your application. Reviewing the migration is therefore the correct next step after this happens, after which it is easy to remove the migration if it isn't what was wanted. |
Hello!
When creating a migration where a data type is converted from larger to smaller a warning is displayed:
An operation was scaffolded that may result in the loss of data. Please review the migration for accuracy
It would be nice to see here some prompt y/n, because some people may not pay attention to it.
The text was updated successfully, but these errors were encountered: