Try to find the .NET SDK PATH on Mac if it Installs to Unexpected Loc #1884
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Our highest failure for .NET SDK Installs on Mac only is that the
InstallationValidator
which checks the hard-coded expected path of Installation does not find .NET in the expected location. Unfortunately, nobody has reported this so we can't get more info from them.To get to this point in the code of
Validation
, everything has to have succeeded, including the installer only returning and exiting 0, which it would only do upon installation success.I'm guessing there is some undocumented case where the .NET SDK is installed to a different location, but I couldn't find where.
Here is our path check. https://github.com/dotnet/vscode-dotnet-runtime/blob/main/vscode-dotnet-runtime-library/src/Acquisition/WinMacGlobalInstaller.ts#L239
According to the installer source code and our documentation, it should only install to this location or with x64 during emulation.
The 64 directory however, is only for when you install a 64-bit SDK on an ARM Mac. We wouldn't expect this to happen because we only install the SDK that matches os.platform(), so we should never install an x64 SDK on an ARM machine.
I'm curious to see where this path is and this will also help us track that. It's a bit of a hack, but I think it will have the desired outcome.