I have added a migration using Add-Migration
, Now If I run Remove-Migration
, it reverts the migration and remove the generated migration file successfully, but gives the error in Package Manager Console also. I could not figure out the exact reason behind it and side effect of it. Is this EF Core bug?
Package Manager Output:
PM> Remove-Migration Removing migration '20180320052521_testMigration'. Reverting model snapshot. Done. Exception calling "Remove" with "0" argument(s): "The given key was not present in the dictionary." PM>
EF Core Version: 2.0.1
The Application is always building when a migration is added to the Project as mentioned in the previous answers.
This one is not actually a Solution, its more a workaround which is working for me at most.
Try to remove your Migration mit following Command
Remove-Migration NameOfMigration
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With