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

Unable to resolve '{dotnet-cli-tool} (>= 1.0.0)' for '.NETCoreApp,Version=v1.0'" on a netcoreapp1.1 #4801

Closed
anangaur opened this issue Mar 14, 2017 · 6 comments
Labels
Resolution:External This issue appears to be External to nuget

Comments

@anangaur
Copy link
Member

As reported on twitter:
https://twitter.com/stevedesmond_ca/status/841020721933475840
image

@emgarten
Copy link
Member

The error message occurs when the package cannot be found on the feed. Verify that your sources are correct and that the package does exist.

The target framework of your project has no impact on the tool.

@SteveDesmond-ca
Copy link

SteveDesmond-ca commented Mar 14, 2017

Steps to reproduce:

  • dotnet new
  • update your csproj to
<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>netcoreapp1.1</TargetFramework>
  </PropertyGroup>

  <ItemGroup>
    <DotNetCliToolReference Include="libyear" Version="0.1.0" />
  </ItemGroup>
</Project>
  • dotnet restore

Expected result:

  • restore succeeds

Observed result:

C:\Program Files\dotnet\sdk\1.0.0\NuGet.targets(97,5): error : Package libyear 0.1.0 is not compatible with netcoreapp1.0 (.NETCoreApp,Version=v1.0). Package libyear 0.1.0 supports: netcoreapp1.1 (.NETCoreApp,Version=v1.1) [D:\Code\LibYear\test\LibYear.TestApp\LibYear.TestApp.csproj]
C:\Program Files\dotnet\sdk\1.0.0\NuGet.targets(97,5): error : One or more packages are incompatible with .NETCoreApp,Version=v1.0. [D:\Code\LibYear\test\LibYear.TestApp\LibYear.TestApp.csproj]

@emgarten
Copy link
Member

@SteveDesmond-ca thanks for the update, that error is referring to compatibility. Tools are restored under netcoreapp1.0 which is why you are seeing this. The target framework of the project is unrelated to the project's framework, tools are executed independently.

@natemcmaster what is the current guidance around creating tools for netcoreapp1.1?

@SteveDesmond-ca
Copy link

Thanks, I assumed as much -- is this documented anywhere / would you like me to?

@natemcmaster
Copy link

Duplicate of #4396. You can only use netcoreapp1.0 TFM. See also https://github.com/dotnet/cli/issues/4764 (which was closed as "by design").

cc @livarcocc @blackdwarf

@emgarten
Copy link
Member

Thanks @natemcmaster

I'm going to close this out, and it looks like the doc concerns are already raised in the other issues.

@emgarten emgarten added the Resolution:External This issue appears to be External to nuget label Mar 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution:External This issue appears to be External to nuget
Projects
None yet
Development

No branches or pull requests

4 participants