title: Restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETCoreApp,Version=v2.0'?
body: <p>I installed a Visual Studio 2017 V15.7.3 and created a new Asp.Net core 2.0 project with template API. The project has the following warning?</p>
  
  <blockquote>
    <p>Severity  Code    Description Project File    Line    Suppression State
    Warning NU1701  Package 'System.Linq.Queryable 4.0.1' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETCoreApp,Version=v2.0'. This package may not be fully compatible with your project. WebApplication3 C:\TEMP\WebApplication3\WebApplication3\WebApplication3.csproj  1   </p>
  </blockquote>
  
  <p>And the entire solution has the following errors. I tried to uninstall and reinstall Visual studio but no luck. Doing the same on another machine doesn't have any of these warnings and errors. </p>
  
  <pre>
  Severity    Code    Description Project File    Line    Suppression State
  Error   NU1202  Package System.Diagnostics.FileVersionInfo 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Diagnostics.FileVersionInfo 4.0.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Security.Cryptography.X509Certificates 4.1.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Security.Cryptography.X509Certificates 4.1.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Net.Primitives 4.0.11 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Net.Primitives 4.0.11 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net45 (.NETFramework,Version=v4.5)
    - portable-net45+win8+wp8+wpa81 (.NETPortable,Version=v0.0,Profile=Profile259)
    - win8 (Windows,Version=v8.0)
    - wp8 (WindowsPhone,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)             
  Error   NU1202  Package System.Reflection.Metadata 1.3.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Reflection.Metadata 1.3.0 does not support any target frameworks.              
  Error   NU1202  Package System.Threading.Timer 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Threading.Timer 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net451 (.NETFramework,Version=v4.5.1)
    - portable-net451+win81+wpa81 (.NETPortable,Version=v0.0,Profile=Profile151)
    - win81 (Windows,Version=v8.1)
    - 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)             
  Error   NU1202  Package System.Threading.Thread 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Threading.Thread 4.0.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - netcore50 (.NETCore,Version=v5.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Collections.Concurrent 4.0.12 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Collections.Concurrent 4.0.12 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net45 (.NETFramework,Version=v4.5)
    - 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)             
  Error   NU1202  Package System.Security.Cryptography.Encoding 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Security.Cryptography.Encoding 4.0.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Diagnostics.Tracing 4.1.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Diagnostics.Tracing 4.1.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net45 (.NETFramework,Version=v4.5)
    - 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)             
  Error   NU1202  Package System.AppContext 4.1.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.AppContext 4.1.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - netstandard (.NETStandard,Version=v0.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Collections.Immutable 1.2.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Collections.Immutable 1.2.0 does not support any target frameworks.              
  Error   NU1202  Package System.Xml.XmlSerializer 4.0.11 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Xml.XmlSerializer 4.0.11 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net45 (.NETFramework,Version=v4.5)
    - portable-net45+win8+wp8+wpa81 (.NETPortable,Version=v0.0,Profile=Profile259)
    - win8 (Windows,Version=v8.0)
    - wp8 (WindowsPhone,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)             
  Error   NU1202  Package System.Runtime.InteropServices.RuntimeInformation 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Runtime.InteropServices.RuntimeInformation 4.0.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Security.Principal 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Security.Principal 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net45 (.NETFramework,Version=v4.5)
    - portable-net45+win8+wp8+wpa81 (.NETPortable,Version=v0.0,Profile=Profile259)
    - win8 (Windows,Version=v8.0)
    - wp8 (WindowsPhone,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)             
  Error   NU1202  Package System.Text.Encoding.CodePages 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Text.Encoding.CodePages 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Net.Sockets 4.1.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Net.Sockets 4.1.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Security.Cryptography.Csp 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Security.Cryptography.Csp 4.0.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Security.Cryptography.Primitives 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Security.Cryptography.Primitives 4.0.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Diagnostics.Contracts 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Diagnostics.Contracts 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net45 (.NETFramework,Version=v4.5)
    - portable-net45+win8+wp8+wpa81 (.NETPortable,Version=v0.0,Profile=Profile259)
    - win8 (Windows,Version=v8.0)
    - wp8 (WindowsPhone,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)             
  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)
    - 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)             
  Error   NU1202  Package System.Runtime.Loader 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Runtime.Loader 4.0.0 supports: net462 (.NETFramework,Version=v4.6.2)                
  Error   NU1202  Package System.Globalization.Calendars 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Globalization.Calendars 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  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 does not support any target frameworks.                
  Error   NU1202  Package Microsoft.Win32.Primitives 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package Microsoft.Win32.Primitives 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Threading.ThreadPool 4.0.10 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Threading.ThreadPool 4.0.10 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - netcore50 (.NETCore,Version=v5.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package Microsoft.Win32.Registry 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package Microsoft.Win32.Registry 4.0.0 does not support any target frameworks.              
  Error   NU1202  Package System.Xml.XPath 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Xml.XPath 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Threading.Tasks.Dataflow 4.6.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Threading.Tasks.Dataflow 4.6.0 does not support any target frameworks.                
  Error   NU1202  Package System.Diagnostics.Process 4.1.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Diagnostics.Process 4.1.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Linq.Parallel 4.0.1 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Linq.Parallel 4.0.1 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - net45 (.NETFramework,Version=v4.5)
    - 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)             
  Error   NU1202  Package System.Console 4.0.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Console 4.0.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Error   NU1202  Package System.Security.Cryptography.Algorithms 4.2.0 is not compatible with netcoreapp2.0 (.NETCoreApp,Version=v2.0). Package System.Security.Cryptography.Algorithms 4.2.0 supports:
    - monoandroid10 (MonoAndroid,Version=v1.0)
    - monotouch10 (MonoTouch,Version=v1.0)
    - xamarinios10 (Xamarin.iOS,Version=v1.0)
    - xamarinmac20 (Xamarin.Mac,Version=v2.0)
    - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
    - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)             
  Warning NU1701  Package 'System.Linq.Queryable 4.0.1' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETCoreApp,Version=v2.0'. This package may not be fully compatible with your project. WebApplication3 C:\TEMP\WebApplication3\WebApplication3\WebApplication3.csproj  1   
  
  </pre>
  
  <hr>
  
  <p><strong>Update:</strong>
  I updated the .Net core to V2.1 and the errors are gone when creating projects targetting V2.1 (the errors remain if targetting V2.0). However, the warning still remains. </p>