Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MSBuild.Sdk.Extras package type 'MSBuildSdk' not supported #159

Open
dgxhubbard opened this issue Apr 3, 2019 · 6 comments
Open

MSBuild.Sdk.Extras package type 'MSBuildSdk' not supported #159

dgxhubbard opened this issue Apr 3, 2019 · 6 comments

Comments

@dgxhubbard
Copy link

I get this error attempting to upgrade Package MSBuild.Sdk.Extras
'MSBuild.Sdk.Extras 2.0.24' has a package type 'MSBuildSdk' that is not supported by project.
This is in a net standard 2.0 project. I was trying to upgrade to visual studio 2019 and had a missing c# target errors and one of the suggestions was to ugrade to latest MSBuild.Sdk.Extras to resolve the error. I am not familiar with json config files where is the package type and what should it be set to.

@dgxhubbard
Copy link
Author

Refer to #111.
Our .net standard 2.0 projects do not have a global.json file.

@dgxhubbard
Copy link
Author

dgxhubbard commented Apr 3, 2019

When we upgraded our old c# projects to the folder style project we used this conversion. But I just found this article.

At the top of our csproj files we have:
Project Sdk="Microsoft.NET.Sdk"

However the article says to use:
Project Sdk="MSBuild.Sdk.Extras/1.6.61"

Is this causing our problem?

@rubo
Copy link

rubo commented Apr 8, 2019

I have the same problem. It's a Xamarin bindings project with Sdk="Microsoft.NET.Sdk" and MonoAndroid81 as the target framework.

@clairernovotny
Copy link
Collaborator

Please ensure you're using the Extras as an SDK reference and that you're using the latest 2.x version.

@pirhano
Copy link

pirhano commented Feb 21, 2020

Any fix for this issue, I'm unable to install the nuget

@TylerKendrick
Copy link

Any fix for this issue, I'm unable to install the nuget

This is intentional behavior. SDK packages shouldn't be referenced.
If you instead update your project SDK target, this is the new way that SDK packages should be used.

One example is to update the following line:
<Project Sdk="Microsoft.NET.Sdk">
To instead look like this:
<Project Sdk="MsBuild.SDK.Extras">
Unless you want a specific version:
<Project Sdk="MsBuild.SDK.Extras/2.0.54">

The behavior you're describing through Nuget is a feature that is documented by the Microsoft team, here: NuGet issue 6484

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants