-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Implicit architecture targeting not in place for dotnet tool install
#21660
Comments
Spent some time investigating this and the problem is that we don't know what the TFM is. When the |
Discussed offline with @joeloff and we don't think this change is going to be do-able for GA. The fundamental issue here is that we don't know what the TFM for a given tool package is when we're determining the RID, and adding this support will be a big fix. At the moment the RID and app host are resolved before the tool package is installed, but we don't know what the package's TFM is until we have it on disk and can look at the package's metadata. To be able to figure out the TFM we'd have to make some significant and potentially risky changes to tool install logic order and content, including some code that is pretty outdated and messy (example: https://github.com/dotnet/sdk/blob/main/src/Cli/dotnet/ToolPackage/ToolPackageInstaller.cs#L178). We've come to the conclusion that we aren't comfortable making this change in QB mode for GA, and we'd prefer to make this change in 6.0.2xx due to the risk. This way, we'd also be able to clean up and update some of the old code that would be too risky to touch for 6.0.1xx. Tagging this issue for team triage to discuss more on Wednesday cc @richlander @marcpopMSFT |
In the case of If this change is too risky for 6.0.100, it's fine to target 6.0.200. |
Moved to 6.0.2xx. Let's include this in the known issues with the workarounds so we have something to point customers at. |
Fixed by #22331 |
The spec talks about implicit RID targeting.
From that doc, these are the implicit RIDs:
Not documented, on Windows these would be slightly different:
My environment:
rich@MacBook-Air-M1-2020 app % dotnet --info | grep RID RID: osx-arm64 rich@MacBook-Air-M1-2020 app % dotnet --version 6.0.100-rc.2.21478.25
This is working, AFAICT, for
dotnet run
.That's failing, but due to a mismatch in versions available on the feeds I have registered, so NP. The key thing is that the CLI is asking for the
osx-x64
package, which is the desired one.Let's look at
dotnet tool install
in contrast.It is pretty obvious that this isn't a good situation. The user needs to know a-priori that
dotnet-serve
needs to be installed with-a x64
. We can and should do that automatically, matchingdotnet run
behavior.The text was updated successfully, but these errors were encountered: