We have upgraded one of our Web projects to ASP.NET Core 2.0, and are now getting errors in other projects because of mismatched assembly version. I am trying to upgrade all our conflicting assemblies to the highest version.
For example, the previous version of System.Collections.Immutable nuget package was 1.3.1, but the one that the ASP.NET Core 2 project references is in version 1.4.0. So I try to change this in the .csproj files where System.Collections.Immutable is referenced:
<PackageReference Include="System.Collections.Immutable" Version="1.4.0" />
However, this causes a compilation error:
The version of Microsoft.NET.Sdk used by this project is insufficient to support references to libraries targeting .NET Standard 1.5 or higher. Please install version 2.0 or higher of the .NET Core SDK.
First of all, I do have .NET Core 2.0 SDK installed. Googling around there was some suggestions that I add a <DependsOnNETStandard> property to the csproj file and reference NETStandard.Library. However, I can't do that because our code makes full use of the .NET Framework, including stuff not in netstandard.
How can I get this to work?
FYI, we are on Visual Studio 15.3.3 and .NET 4.6.2.