Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ASP .NET Core 2 MVC error NU1202 creating project on VS 2017 and NET CLI

I have installed VS2017 15.3.0 and .NET Core 2.0 and have created a default Web MVC application on VS 2017 and I got the following errors:

Error NU1202

Package System.Threading.Overlapped 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Threading.Overlapped 4.0.1 supports: netstandard1.3 (.NETStandard,Version=v1.3)

Error NU1202

Package System.IO.Compression 4.1.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.IO.Compression 4.1.0

supports:

  • monoandroid10 (MonoAndroid,Version=v1.0)

  • monotouch10 (MonoTouch,Version=v1.0)

  • net45 (.NETFramework,Version=v4.5)

  • netcore50 (.NETCore,Version=v5.0)

  • netstandard1.1 (.NETStandard,Version=v1.1)

  • netstandard1.3 (.NETStandard,Version=v1.3)

  • portable-net45+win8+wpa81 (.NETPortable,Version=v0.0,Profile=Profile111)

  • win8 (Windows,Version=v8.0)

  • wpa81 (WindowsPhoneApp,Version=v8.1)

  • xamarinios10 (Xamarin.iOS,Version=v1.0)

  • xamarinmac20 (Xamarin.Mac,Version=v2.0)

  • xamarintvos10 (Xamarin.TVOS,Version=v1.0)

  • xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)

The same errors occours using NET CLI with the command: dotnet new mvc

I've tried update nuget: Install-Package NuGet.CommandLine -Version 4.3.0

But it doesn´t works.

So I have dotnet core2 installed, with Visual Studio 2017 with update 15.3.0 and NuGet 4.3.0

What am I missing here?

like image 893
Miriam Estela Siqueira Avatar asked Aug 22 '17 15:08

Miriam Estela Siqueira


1 Answers

I had a similar issue, albeit with different assemblies, and the suggestion from MS was to run the following command in the Package Manager Console:

PM> dotnet nuget locals all --clear
like image 119
Stephen H Avatar answered Oct 18 '22 01:10

Stephen H