Cannot install tool on macOS high sierra(temp fix merged)
See original GitHub issueSteps to reproduce
- Using
2.2.0-preview1-008000
on high sierra - Create a console app targeting
netcoreapp2.1
and setPackAsTool
property totrue
. (sayhi.csproj
) - Create a nuget.config file to add
dotnet-core
feed and a local folder for the produced nupkg file. - Use
dotnet pack
to create a nupkg file from the tool app. - Use
dotnet install tool -g --configfile $(pwd)/nuget.config sayhi
Expected behavior
Installs the tool
Actual behavior
Error that the package is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1) / osx.10.13-x64
but only supports netcoreapp2.1 (.NETCoreApp,Version=v2.1) / any
:
$ dotnet install tool -g --configfile $(pwd)/nuget.config sayhi
Install failed. Failed to download package:
NuGet returned:
Failed to restore package.
WorkingDirectory:
Arguments: restore /var/folders/b1/p_sdf_v932sfdvr0ccxt2gd80000gn/T/4zstq4rl.ya5/jaj1vnsm.wf1.csproj --configfile /Users/martin/tmp/toolstest/sayhi/nuget.config --runtime osx.10.13-x64 /p:BaseIntermediateOutputPath=\"/Users/martin/.dotnet/tools/sayhi/tn02uk3w.ykb\"
Output: Restoring packages for /var/folders/b1/p_sdf_v932sfdvr0ccxt2gd80000gn/T/4zstq4rl.ya5/jaj1vnsm.wf1.csproj...
Installing Microsoft.NETCore.Platforms 2.1.0-preview1-26116-01.
Installing sayhi 1.0.0.
/var/folders/b1/p_sdf_v932sfdvr0ccxt2gd80000gn/T/4zstq4rl.ya5/jaj1vnsm.wf1.csproj : error NU1202: Package sayhi 1.0.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1) / osx.10.13-x64. Package sayhi 1.0.0 supports: netcoreapp2.1 (.NETCoreApp,Version=v2.1) / any
Restore failed in 1.26 sec for /var/folders/b1/p_sdf_v932sfdvr0ccxt2gd80000gn/T/4zstq4rl.ya5/jaj1vnsm.wf1.csproj.
Environment data
dotnet --info
output:
.NET Command Line Tools (2.2.0-preview1-008000)
Product Information:
Version: 2.2.0-preview1-008000
Commit SHA-1 hash: 02a98d4e63
Runtime Environment:
OS Name: Mac OS X
OS Version: 10.13
OS Platform: Darwin
RID: osx.10.12-x64
Base Path: /usr/local/share/dotnet/sdk/2.2.0-preview1-008000/
Microsoft .NET Core Shared Framework Host
Version : 2.1.0-preview1-26116-04
Build : eeb3a84e2142aba791fe003564b8afd048c45ff9
cc @wli3
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:5 (1 by maintainers)
Top Results From Across the Web
High Sierra installation stuck
Hi, I am trying to upgrade from os x 10.9.5 to High Sierra for my MacBook Pro - Mid 2012 but the installation...
Read more >Mac Installation Errors You Encounter and How to Fix Them
In this guide, we will look at some of the installation problems that tend to occur with new releases of the Mac operating...
Read more >MacBook Air Sierra install fail: Couldn't mount base system ...
So download Sierra, open the dmg and the included pkg and install the Sierra installer.app to /Applications. From there create a new installer...
Read more >Fixing Mac OS X Install Errors “can't be verified” and “ ...
Try running again” error message. Sometimes these can be resolved by simply rebooting and trying to reinstall OS X again (or re-downloading the ......
Read more >9 Ways to Fix an Error Occurred While Preparing the ...
Follow this guide to learn 9 solutions on how to solve an error occurred while preparing the installation big sur or sierra.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This problem will be resolved after https://github.com/dotnet/cli/issues/8617 is done
The temp fix is merged, keep it on at least until runtime.json is updated