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

The specified framework 'Microsoft.NETCore.App', version '2.1.1' was not found after the SDK is uninstalled #9519

Closed
JanFredrikD opened this Issue Jun 20, 2018 · 28 comments

Comments

Projects
None yet
@JanFredrikD

JanFredrikD commented Jun 20, 2018

Steps to reproduce

You need to already have the Microsoft.NETCore.App 2.1.0 SDK installed with a web project with the versionless Microsoft.AspNetCore.App in the .csproj.

Install the Microsoft.NETCore.App 2.1.1 SDK and debug your project.
I got it from here:
https://github.com/dotnet/versions/tree/7a833dddfddc27f2074b755b94234a25b9757637/build-info/dotnet/product/cli/release

Uninstall the Microsoft.NETCore.App 2.1.1 SDK.

Debug the web project again.

Expected behavior

Should run with version 2.1.0.

Actual behavior

Getting the following error message when debugging:
It was not possible to find any compatible framework version
The specified framework 'Microsoft.NETCore.App', version '2.1.1' was not found.
The following versions are installed:
2.1.0 at [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]

I tried with a repair on the 2.1.0 SDK, reboot, all changes are rolled back from the source control. I cannot see a reference to the 2.1.1 version anywhere.
Where does it think that I should target 2.1.1 after I have uninstalled it?

Environment data

dotnet --info output:
.NET Core SDK (reflecting any global.json):
Version: 2.1.300
Commit: adab45b

Runtime Environment:
OS Name: Windows
OS Version: 6.1.7601
OS Platform: Windows
RID: win7-x64
Base Path: C:\Program Files\dotnet\sdk\2.1.300\

Host (useful for support):
Version: 2.1.0
Commit: caa7b7e2ba

.NET Core SDKs installed:
1.0.0-preview1-002702 [C:\Program Files\dotnet\sdk]
1.0.0-preview2-003121 [C:\Program Files\dotnet\sdk]
1.0.0-preview2-003131 [C:\Program Files\dotnet\sdk]
1.0.0 [C:\Program Files\dotnet\sdk]
1.0.2 [C:\Program Files\dotnet\sdk]
1.0.3 [C:\Program Files\dotnet\sdk]
1.0.4 [C:\Program Files\dotnet\sdk]
1.1.0 [C:\Program Files\dotnet\sdk]
2.0.0 [C:\Program Files\dotnet\sdk]
2.0.2 [C:\Program Files\dotnet\sdk]
2.0.3 [C:\Program Files\dotnet\sdk]
2.1.2 [C:\Program Files\dotnet\sdk]
2.1.4 [C:\Program Files\dotnet\sdk]
2.1.100 [C:\Program Files\dotnet\sdk]
2.1.101 [C:\Program Files\dotnet\sdk]
2.1.102 [C:\Program Files\dotnet\sdk]
2.1.103 [C:\Program Files\dotnet\sdk]
2.1.104 [C:\Program Files\dotnet\sdk]
2.1.200 [C:\Program Files\dotnet\sdk]
2.1.201 [C:\Program Files\dotnet\sdk]
2.1.300 [C:\Program Files\dotnet\sdk]

.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.1.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.1.1 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.1.1 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 1.0.0-rc2-3002702 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 1.0.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 1.0.1 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 1.0.4 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 1.0.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 1.1.1 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 1.1.2 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.0.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.0.3 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.0.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.0.6 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.0.7 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]

To install additional .NET Core runtimes or SDKs:
https://aka.ms/dotnet-download

@JanFredrikD

This comment has been minimized.

Show comment
Hide comment
@JanFredrikD

JanFredrikD Jun 20, 2018

I fixed it now. The .NET Core Runtime of Microsoft.AspNetCore.App 2.1.1 was still installed, so I deleted the following folder:
C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App\2.1.1

JanFredrikD commented Jun 20, 2018

I fixed it now. The .NET Core Runtime of Microsoft.AspNetCore.App 2.1.1 was still installed, so I deleted the following folder:
C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App\2.1.1

@livarcocc

This comment has been minimized.

Show comment
Hide comment
@livarcocc

livarcocc Jun 20, 2018

Member

Was it just the folder that was there or were all the contents for it there as well?

Member

livarcocc commented Jun 20, 2018

Was it just the folder that was there or were all the contents for it there as well?

@livarcocc livarcocc added this to the Discussion milestone Jun 20, 2018

@JanFredrikD

This comment has been minimized.

Show comment
Hide comment
@JanFredrikD

JanFredrikD Jun 20, 2018

All the content was there as well.

JanFredrikD commented Jun 20, 2018

All the content was there as well.

@JanFredrikD

This comment has been minimized.

Show comment
Hide comment
@JanFredrikD

JanFredrikD Jun 20, 2018

It also worked if I renamed the folder to 0.1.1

JanFredrikD commented Jun 20, 2018

It also worked if I renamed the folder to 0.1.1

@sonicdivx

This comment has been minimized.

Show comment
Hide comment
@sonicdivx

sonicdivx Jun 21, 2018

yeah getting the error also updating AspNetCore.All to latest. Following the link in output
http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409

I uninstalled / reinstalled 2.1.300 . Though my folder is is 2.1.0. Going to try rename trick @JanFredrikD mentioned

Also I used SDK

sonicdivx commented Jun 21, 2018

yeah getting the error also updating AspNetCore.All to latest. Following the link in output
http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409

I uninstalled / reinstalled 2.1.300 . Though my folder is is 2.1.0. Going to try rename trick @JanFredrikD mentioned

Also I used SDK

@tstojecki

This comment has been minimized.

Show comment
Hide comment
@tstojecki

tstojecki Jun 21, 2018

Ran into this problem too. I installed the latest SDK - 2.1 SDK (v2.1.300) and updated the package Microsoft.AspNetCore.App to v2.1.1

When running dotnet run, I get
The specified framework 'Microsoft.AspNetCore.App', version '2.1.1' was not found.
...

  • The following versions are installed:
    2.1.0 at [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]

The following is installed on my machine:

  • Microsoft .NET Core SDK 2.1.300 (x64)
  • Microsoft .NET Core Runtime - 2.1.0 (x64)

and under the Program Files\dotnet\shared folder I have 2.1.0 folders everywhere

  • Microsoft.AspNetCore.All
    -- 2.1.0
  • Microsoft.AspNetCore.App
    -- 2.1.0
  • Microsoft.NETCore.App
    -- 2.1.0

tstojecki commented Jun 21, 2018

Ran into this problem too. I installed the latest SDK - 2.1 SDK (v2.1.300) and updated the package Microsoft.AspNetCore.App to v2.1.1

When running dotnet run, I get
The specified framework 'Microsoft.AspNetCore.App', version '2.1.1' was not found.
...

  • The following versions are installed:
    2.1.0 at [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]

The following is installed on my machine:

  • Microsoft .NET Core SDK 2.1.300 (x64)
  • Microsoft .NET Core Runtime - 2.1.0 (x64)

and under the Program Files\dotnet\shared folder I have 2.1.0 folders everywhere

  • Microsoft.AspNetCore.All
    -- 2.1.0
  • Microsoft.AspNetCore.App
    -- 2.1.0
  • Microsoft.NETCore.App
    -- 2.1.0
@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 21, 2018

Contributor

@tstojecki how did you update the package? did the NuGet package manager offer you to update the package reference?

The idea is that you don't specify the version of the package in the project file and let the tooling choose a version for you:

<Project Sdk="Microsoft.NET.Sdk.Web">
…
<ItemGroup>
   <!--  No Version needed -->
  <PackageReference Include="Microsoft.AspNetCore.App" />
</ItemGroup>
</Project>
Contributor

dasMulli commented Jun 21, 2018

@tstojecki how did you update the package? did the NuGet package manager offer you to update the package reference?

The idea is that you don't specify the version of the package in the project file and let the tooling choose a version for you:

<Project Sdk="Microsoft.NET.Sdk.Web">
…
<ItemGroup>
   <!--  No Version needed -->
  <PackageReference Include="Microsoft.AspNetCore.App" />
</ItemGroup>
</Project>
@sonicdivx

This comment has been minimized.

Show comment
Hide comment
@sonicdivx

sonicdivx Jun 21, 2018

@dasMulli That makes sense, but (and I did not create the project I am working in) I wonder if it gets assigned when create the project if not using the current releases.

sonicdivx commented Jun 21, 2018

@dasMulli That makes sense, but (and I did not create the project I am working in) I wonder if it gets assigned when create the project if not using the current releases.

@tstojecki

This comment has been minimized.

Show comment
Hide comment
@tstojecki

tstojecki Jun 21, 2018

@dasMulli Yes, the NuGet package manager suggested the update to 2.1.1.

What did it for me was installing this specific version https://github.com/dotnet/versions/tree/7a833dddfddc27f2074b755b94234a25b9757637/build-info/dotnet/product/cli/release/2.1.1

I am confused though, installing the .NET Core 2.1 SDK (v2.1.301) from
https://www.microsoft.com/net/download/windows

appears to be installing 2.1.0 framework files under program files/dotnet/shared
Microsoft.AspNetCore.All
-- 2.1.0
Microsoft.AspNetCore.App
-- 2.1.0
Microsoft.NETCore.App
-- 2.1.0

which creates an issue when the microsoft.aspnetcore.app package is updated to 2.1.1.

Installing 2.1.1 build from the github link above installs the proper files under

Microsoft.AspNetCore.All
-- 2.1.0
-- 2.1.1
Microsoft.AspNetCore.App
-- 2.1.0
-- 2.1.1
Microsoft.NETCore.App
-- 2.1.0
-- 2.1.1

So installing 2.1.301 of SDK from the official download page is not enough to run with microsoft.aspnetcore.app 2.1.1?

tstojecki commented Jun 21, 2018

@dasMulli Yes, the NuGet package manager suggested the update to 2.1.1.

What did it for me was installing this specific version https://github.com/dotnet/versions/tree/7a833dddfddc27f2074b755b94234a25b9757637/build-info/dotnet/product/cli/release/2.1.1

I am confused though, installing the .NET Core 2.1 SDK (v2.1.301) from
https://www.microsoft.com/net/download/windows

appears to be installing 2.1.0 framework files under program files/dotnet/shared
Microsoft.AspNetCore.All
-- 2.1.0
Microsoft.AspNetCore.App
-- 2.1.0
Microsoft.NETCore.App
-- 2.1.0

which creates an issue when the microsoft.aspnetcore.app package is updated to 2.1.1.

Installing 2.1.1 build from the github link above installs the proper files under

Microsoft.AspNetCore.All
-- 2.1.0
-- 2.1.1
Microsoft.AspNetCore.App
-- 2.1.0
-- 2.1.1
Microsoft.NETCore.App
-- 2.1.0
-- 2.1.1

So installing 2.1.301 of SDK from the official download page is not enough to run with microsoft.aspnetcore.app 2.1.1?

@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 21, 2018

Contributor

@tstojecki so https://download.microsoft.com/download/D/0/4/D04C5489-278D-4C11-9BD3-6128472A7626/dotnet-sdk-2.1.301-win-x64.exe for me installed 2.1.1 version of all shared frameworks. which exact installer did you use?

Please don't use a fixed version from NuGet as mentioned above.

@JunTaoLuo @natemcmaster is the websdk supposed to set properties to disallow the package manager to offer updates to the sharedfx packages? Maybe this should be made even stricter, possibly even emit a build warning if a package version is set by the user.

Contributor

dasMulli commented Jun 21, 2018

@tstojecki so https://download.microsoft.com/download/D/0/4/D04C5489-278D-4C11-9BD3-6128472A7626/dotnet-sdk-2.1.301-win-x64.exe for me installed 2.1.1 version of all shared frameworks. which exact installer did you use?

Please don't use a fixed version from NuGet as mentioned above.

@JunTaoLuo @natemcmaster is the websdk supposed to set properties to disallow the package manager to offer updates to the sharedfx packages? Maybe this should be made even stricter, possibly even emit a build warning if a package version is set by the user.

@JunTaoLuo

This comment has been minimized.

Show comment
Hide comment
@JunTaoLuo

JunTaoLuo Jun 22, 2018

Collaborator

The current implementation only sets the property to disallow package manager from offering updates when there is no explicit version set on the Microsoft.AspNetCore.App package dependency. If you specify an explicit version, we no-op all of our implicit logic. Is the proposal to add a warning when explicit versions are specified on references to the aspnet metapackages?

Collaborator

JunTaoLuo commented Jun 22, 2018

The current implementation only sets the property to disallow package manager from offering updates when there is no explicit version set on the Microsoft.AspNetCore.App package dependency. If you specify an explicit version, we no-op all of our implicit logic. Is the proposal to add a warning when explicit versions are specified on references to the aspnet metapackages?

@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 22, 2018

Contributor

@JunTaoLuo yes that's the proposal. Opened aspnet/websdk#369 to properly track/discuss it.

Contributor

dasMulli commented Jun 22, 2018

@JunTaoLuo yes that's the proposal. Opened aspnet/websdk#369 to properly track/discuss it.

@JanFredrikD

This comment has been minimized.

Show comment
Hide comment
@JanFredrikD

JanFredrikD Jun 22, 2018

When you install the SDK for 2.1.1, it also installs the 2.1.1 runtime for both .NET Core and ASP.NET Core. When you uninstall the SDK, it does not remove the runtime. The issue is that Visual Studio does not check for the highest SDK version when debugging, it also checks for the highest runtime version. I think it would be more correct to only use for the highest SDK version, and instead give a warning that you have a higher runtime version.

JanFredrikD commented Jun 22, 2018

When you install the SDK for 2.1.1, it also installs the 2.1.1 runtime for both .NET Core and ASP.NET Core. When you uninstall the SDK, it does not remove the runtime. The issue is that Visual Studio does not check for the highest SDK version when debugging, it also checks for the highest runtime version. I think it would be more correct to only use for the highest SDK version, and instead give a warning that you have a higher runtime version.

@JanFredrikD

This comment has been minimized.

Show comment
Hide comment
@JanFredrikD

JanFredrikD Jun 22, 2018

I installed the 2.1.1 SDK today, but had to do a repair as the 2.1.1 folder that I had deleted earlier was not created during the regular install.

JanFredrikD commented Jun 22, 2018

I installed the 2.1.1 SDK today, but had to do a repair as the 2.1.1 folder that I had deleted earlier was not created during the regular install.

@livarcocc

This comment has been minimized.

Show comment
Hide comment
@livarcocc

livarcocc Jun 22, 2018

Member

@JunTaoLuo any idea why the 2.1.1 runtime of asp.net would not have been removed when removing the SDK? That would have been my expectation.

Member

livarcocc commented Jun 22, 2018

@JunTaoLuo any idea why the 2.1.1 runtime of asp.net would not have been removed when removing the SDK? That would have been my expectation.

@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 22, 2018

Contributor

I believe the installers will do some sort of ref-counting and the runtime installer is a sub-installer of the SDK. so if you remove a folder and the MSI it is associated with is still installed, the folder won't be recreated.

Contributor

dasMulli commented Jun 22, 2018

I believe the installers will do some sort of ref-counting and the runtime installer is a sub-installer of the SDK. so if you remove a folder and the MSI it is associated with is still installed, the folder won't be recreated.

@MarcusChamberlain

This comment has been minimized.

Show comment
Hide comment
@MarcusChamberlain

MarcusChamberlain Jun 23, 2018

I'm getting the same error from a brand new project using the latest v2.1.301 from the downloads page. I eventually uninstalled the sdk and rolled back to v2.1.300 and everything is working again. Something weird is going on with the latest installer.

MarcusChamberlain commented Jun 23, 2018

I'm getting the same error from a brand new project using the latest v2.1.301 from the downloads page. I eventually uninstalled the sdk and rolled back to v2.1.300 and everything is working again. Something weird is going on with the latest installer.

@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 23, 2018

Contributor

@MarcusChamberlain what exactly is the error?
was it the result of a project created with dotnet new or through VS? can you upload the problematic project?

Contributor

dasMulli commented Jun 23, 2018

@MarcusChamberlain what exactly is the error?
was it the result of a project created with dotnet new or through VS? can you upload the problematic project?

@MarcusChamberlain

This comment has been minimized.

Show comment
Hide comment
@MarcusChamberlain

MarcusChamberlain Jun 23, 2018

Project is attached. It was created through Visual Studio 15.7.4. One thing I noticed while setting this up is it's only the Docker version that seems to be breaking (for me at least) in 2.1.301. If I run the app outside of Docker in IIS Express it works fine. Maybe something going on with the docker hub images?

TestWebApp.zip

The full error is:

It was not possible to find any compatible framework version
The specified framework 'Microsoft.AspNetCore.App', version '2.1.1' was not found.
- Check application dependencies and target a framework version installed at:
/usr/share/dotnet/
- Installing .NET Core prerequisites might help resolve this problem:
http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409
- The .NET Core framework and SDK can be installed from:
https://aka.ms/dotnet-download
- The following versions are installed:
2.1.0 at [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
The target process exited without raising a CoreCLR started event. Ensure that the target process is configured to use .NET Core. This may be expected if the target process did not run on .NET Core.

MarcusChamberlain commented Jun 23, 2018

Project is attached. It was created through Visual Studio 15.7.4. One thing I noticed while setting this up is it's only the Docker version that seems to be breaking (for me at least) in 2.1.301. If I run the app outside of Docker in IIS Express it works fine. Maybe something going on with the docker hub images?

TestWebApp.zip

The full error is:

It was not possible to find any compatible framework version
The specified framework 'Microsoft.AspNetCore.App', version '2.1.1' was not found.
- Check application dependencies and target a framework version installed at:
/usr/share/dotnet/
- Installing .NET Core prerequisites might help resolve this problem:
http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409
- The .NET Core framework and SDK can be installed from:
https://aka.ms/dotnet-download
- The following versions are installed:
2.1.0 at [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
The target process exited without raising a CoreCLR started event. Ensure that the target process is configured to use .NET Core. This may be expected if the target process did not run on .NET Core.
@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 23, 2018

Contributor

looks like you have an outdated version of the base image on your machine.
can you do a

docker pull microsoft/dotnet:2.1-aspnetcore-runtime

and see if it pulls a newer version? then try rebuilding your image.

Contributor

dasMulli commented Jun 23, 2018

looks like you have an outdated version of the base image on your machine.
can you do a

docker pull microsoft/dotnet:2.1-aspnetcore-runtime

and see if it pulls a newer version? then try rebuilding your image.

@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 23, 2018

Contributor

alternatively, you could explicitly change your Dockerfile to use the microsoft/dotnet:2.1.1-aspnetcore-runtime image.

Usually this isn't supposed to happen since your app would build for a .0 patch version of the runtime and the newer runtimes would light up and be used if installed on the machine / docker image. For ASP.NET Core 2.1.1, there were a few tooling related changes in the package that require to use 2.1.1 during build and thus upgrading the minimum required runtime version to 2.1.1. If all goes well, this won't be a problem for 2.1.2 and up (you'd just be left with an image with an old runtime version in your case. but that's an issue with docker builds without doing a docker pull as part of the build regardless of the asp.net core version)

Contributor

dasMulli commented Jun 23, 2018

alternatively, you could explicitly change your Dockerfile to use the microsoft/dotnet:2.1.1-aspnetcore-runtime image.

Usually this isn't supposed to happen since your app would build for a .0 patch version of the runtime and the newer runtimes would light up and be used if installed on the machine / docker image. For ASP.NET Core 2.1.1, there were a few tooling related changes in the package that require to use 2.1.1 during build and thus upgrading the minimum required runtime version to 2.1.1. If all goes well, this won't be a problem for 2.1.2 and up (you'd just be left with an image with an old runtime version in your case. but that's an issue with docker builds without doing a docker pull as part of the build regardless of the asp.net core version)

@MarcusChamberlain

This comment has been minimized.

Show comment
Hide comment
@MarcusChamberlain

MarcusChamberlain Jun 23, 2018

@dasMulli : That seemed to fix it. Strange, I've never had to pull the latest images manually before. I wonder if this fixes the issue for anyone else - hopefully it does and I didn't derail the comments with something unrelated.

MarcusChamberlain commented Jun 23, 2018

@dasMulli : That seemed to fix it. Strange, I've never had to pull the latest images manually before. I wonder if this fixes the issue for anyone else - hopefully it does and I didn't derail the comments with something unrelated.

@dasMulli

This comment has been minimized.

Show comment
Hide comment
@dasMulli

dasMulli Jun 23, 2018

Contributor

not at all.

The reason it didn't break before is likely that for 2.0.* runtime updates, the project is actually built for 2.0.0 and uses any later 2.0.* runtime if available on the image. And if you didn't update the 2.0.* asp.net core NuGet packages manually, it would still work (since the 2.0.* runtime stores contained all previous NuGet packages of the 2.0.* range). So if you never opened the NuGet package manager and updated all the deps for the asp.net core patch releases, old images still worked.

In 2.1.0+, the same is done for asp.net core as well. However, 2.1.1 is special as it contains some important changes that affect your build so the app will be built for the asp.net core 2.1.1 runtime, not for the 2.1.0 runtime as originally planned. Though if everything works out, from the next patch update forward, your app will always be built for 2.1.1 and any newer 2.1.* runtime will just be used at run-time. This change for 2.1.1 however requires that you use the latest docker image or runtime on target servers.

If anything, we may have discovered some shortcomings of the VS build tooling for docker. No idea whom to tag for this though. @livarcocc any idea?

docker build has a --pull flag to ensure that all images used during the build of a container are up to date. I don't know how this works for docker-compose or how VS handles building the containers involved. If it builds all projects' Dockerimage first and then uses compose, VS could improve here by passing along the --pull option.

Contributor

dasMulli commented Jun 23, 2018

not at all.

The reason it didn't break before is likely that for 2.0.* runtime updates, the project is actually built for 2.0.0 and uses any later 2.0.* runtime if available on the image. And if you didn't update the 2.0.* asp.net core NuGet packages manually, it would still work (since the 2.0.* runtime stores contained all previous NuGet packages of the 2.0.* range). So if you never opened the NuGet package manager and updated all the deps for the asp.net core patch releases, old images still worked.

In 2.1.0+, the same is done for asp.net core as well. However, 2.1.1 is special as it contains some important changes that affect your build so the app will be built for the asp.net core 2.1.1 runtime, not for the 2.1.0 runtime as originally planned. Though if everything works out, from the next patch update forward, your app will always be built for 2.1.1 and any newer 2.1.* runtime will just be used at run-time. This change for 2.1.1 however requires that you use the latest docker image or runtime on target servers.

If anything, we may have discovered some shortcomings of the VS build tooling for docker. No idea whom to tag for this though. @livarcocc any idea?

docker build has a --pull flag to ensure that all images used during the build of a container are up to date. I don't know how this works for docker-compose or how VS handles building the containers involved. If it builds all projects' Dockerimage first and then uses compose, VS could improve here by passing along the --pull option.

@livarcocc

This comment has been minimized.

Show comment
Hide comment
@livarcocc

livarcocc Jun 24, 2018

Member

Ok, this is now a super long issue where I believe the original issues have now been addressed. We had problems pushing the SDK bits through on release for 2.1.301 and the nuget packages were published before the SDK. This is now addressed.

As for docker, I am tagging @MichaelSimons to see if he knows exactly who to talk to in VS or if there is a repo on github that we can file an issue on.

For now, I am closing this one though.

Member

livarcocc commented Jun 24, 2018

Ok, this is now a super long issue where I believe the original issues have now been addressed. We had problems pushing the SDK bits through on release for 2.1.301 and the nuget packages were published before the SDK. This is now addressed.

As for docker, I am tagging @MichaelSimons to see if he knows exactly who to talk to in VS or if there is a repo on github that we can file an issue on.

For now, I am closing this one though.

@livarcocc livarcocc closed this Jun 24, 2018

@MichaelSimons

This comment has been minimized.

Show comment
Hide comment
@MichaelSimons

MichaelSimons Jun 25, 2018

Contributor

Any Issues related to the VS Docker tooling should get logged at https://github.com/Microsoft/DockerTools/issues.

Contributor

MichaelSimons commented Jun 25, 2018

Any Issues related to the VS Docker tooling should get logged at https://github.com/Microsoft/DockerTools/issues.

@CarlosTorrecillas

This comment has been minimized.

Show comment
Hide comment
@CarlosTorrecillas

CarlosTorrecillas Jul 13, 2018

Thanks for this! It made my day!! @JanFredrikD

CarlosTorrecillas commented Jul 13, 2018

Thanks for this! It made my day!! @JanFredrikD

@rob-glas

This comment has been minimized.

Show comment
Hide comment
@rob-glas

rob-glas Aug 22, 2018

I had this issues and had to remove all the old versions of aspnetcore.all and then reinstall the latest version of the .netcore sdk. The output from my project directed me http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409 here to download it.

rob-glas commented Aug 22, 2018

I had this issues and had to remove all the old versions of aspnetcore.all and then reinstall the latest version of the .netcore sdk. The output from my project directed me http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409 here to download it.

@Jan-Hettich

This comment has been minimized.

Show comment
Hide comment
@Jan-Hettich

Jan-Hettich Aug 23, 2018

The error message might be misleading. I got this when the actual error was that I just had a missing NuGet package (Microsoft.EntityFrameworkCore.Design).

Jan-Hettich commented Aug 23, 2018

The error message might be misleading. I got this when the actual error was that I just had a missing NuGet package (Microsoft.EntityFrameworkCore.Design).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment