Skip to content

NETSDK1061: The project was restored using Microsoft.NETCore.App version 2.1.6, but with current settings, version 2.1.0 would be used instead.  #2682

@jkotas

Description

@jkotas

From @gpresland on November 19, 2018 21:38

Creating a simple project from scratch and attempting to build it throws multiple errors with SDK 2.1.500.

Create a new project with:

dotnet new webapi -o example
cd example
code

Inside Visual Studio Code run:

dotnet publish -c Release -r win10-x64

You will be spammed with errors such as:

[fail]: OmniSharp.MSBuild.ProjectLoader
        NETSDK1061: The project was restored using Microsoft.NETCore.App version 2.1.6, but with current settings, version 2.1.0 would be used instead. To resolve this issue, make sure the same settings are used for restore and for subsequent operations such as build or publish. Typically this issue can occur if the RuntimeIdentifier property is set during build or publish but not during restore. For more information, see https://aka.ms/dotnet-runtime-patch-selection.

Copied from original issue: dotnet/coreclr#21095

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions