x86 .Net Core application fails to launch and debug via Visual Studio 2017

Today I had a random issue following changing one of my .Net Core projects. Usually I run these AnyCPU but this one needed to be X86 due to a third party library. I've done this before and had no issues but today VS seemed to launch the app and then immediately quit with an error exit code but no useful information!

So far whenever I hit something like this I always try and run it via the console using dotnet run in the project directory. Fortunately this showed the issue straight away:
It was not possible to find any compatible framework version
The specified framework 'Microsoft.NETCore.App', version '2.1.5' was not found.
  - Check application dependencies and target a framework version installed at:
      C:\Program Files (x86)\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.0.3 at [C:\Program Files (x86)\dotnet\shared\Microsoft.NETCore.App]
      2.1.0 at [C:\Program Files (x86)\dotnet\shared\Microsoft.NETCore.App]
      2.1.2 at [C:\Program Files (x86)\dotnet\shared\Microsoft.NETCore.App]
      2.1.4 at [C:\Program Files (x86)\dotnet\shared\Microsoft.NETCore.App]

I had updated my x64 dotnet core but not x86. I hope the VS Tooling gets updated to point this out as its not immediately obvious.

Comments

Popular posts from this blog

Can you use BuildRoot with Windows Subsystem for Linux......

DotNet CLI , private NuGet feeds and Linux...

WebUSB - An unexpected update...