Closed v-xiaofchen closed 7 months ago
Here's the line in question:
This looks like an incorrect use of System.CommandLine to me - we're getting Environment.GetCommandLineArgs()
in the static constructor of a type - this should only happen sometime after Main(stirng[] argv)
.
To Reproduce
1.install dotnet-core-uninstall(1.7.0) from https://dnceng.visualstudio.com/_apis/resources/Containers/16714346/drop-osx?itemPath=drop-osx%2Fdotnet-core-uninstall.tar.gz
3.Install SDK 8.0.201from https://dotnet.microsoft.com/en-us/download/dotnet/8.0
Expected Result:
The version(s) of the .NET 8 SDK you installed appear in the output.
Actual Result:
Throw an unhandled exception in dotnet-core-uninstall list output.
dotnet --info:
Note:
This issue also repro on.NET 6/7.