Microsoft.EntityFrameworkCore.Design' has different version then 'Microsoft.EntityFrameworkCore.Tools'

entity-framework-core sqlite

Question

i have asp dot net core project and i need to make command

$ dotnet ef database update

But after updating of dotnet this command is causing error like this:

...Check that 'Microsoft.EntityFrameworkCore.Design' has been
added to "dependencies" in the startup project and that the
version of 'Microsoft.EntityFrameworkCore.Tools' in "tools"
and 'Microsoft.EntityFrameworkCore.Design' are the same...

I have a linux platform with 1.0.0-preview3-003590 version of dotnet. Partially, my project.json looks like that:

"dependencies": {
    ...
    "Microsoft.AspNetCore.Diagnostics": "1.0.0",
    "Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore": "1.0.0",
    "Microsoft.AspNetCore.Identity.EntityFrameworkCore": "1.0.0",
    "Microsoft.EntityFrameworkCore.Sqlite": "1.0.0",
    "Microsoft.EntityFrameworkCore.Sqlite.Design": {
        "version": "1.0.0",
        "type": "build"
    },
    "Microsoft.EntityFrameworkCore.Tools": {
        "version": "1.0.0-preview2-final", // and here is no 1.0.0 version!
        "type": "build"
    },
    ...
},
"tools": {
    ...
    "Microsoft.EntityFrameworkCore.Tools": "1.0.0-preview2-final",
},

It looks like i have different versions of Tools and Design packages. But there is no package 1.0.0 of tools in nuget. Also i tried to downgrade all EF packages to 1.0.0-preview2-final version. And it is not work for me.

This problem is fully reproducible with project, generated by YO and with test project of entity framework core on my machine.

How do i need change my project.json to successfully update database?

1
1
9/13/2016 4:20:30 PM

Popular Answer

Solved by installing of preview 2 of dotnet instead of preview 3.

0
9/29/2016 10:42:26 PM


Related Questions





Related

Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow