dotnet / dotnet/cli-lab

Unhandled exception. System.TypeInitializationException: The type initializer for 'Microsoft.DotNet.Tools.Uninstall.Shared.Utils.RuntimeInfo' threw an exception. ---> System.DllNotFoundException: Unable to load shared library 'System.Native' or one of its dependencies.

Open
#252 0 comments 0 reactions 0 assignees View on GitHub
Area-Uninstall-Tool
Dominant language
C#
Stars
774
Forks
72
Avg merge
1d 23h
Merged PRs (30d)
2

Description

I am trying to uninstall .Net version 7 from my mac using the steps mentioned for macos. My Mac version is "macOS High Sierra, version 10.13.6". I am getting below error
Unhandled exception. System.TypeInitializationException: The type initializer for 'Microsoft.DotNet.Tools.Uninstall.Shared.Utils.RuntimeInfo' threw an exception.
---> System.DllNotFoundException: Unable to load shared library 'System.Native' or one of its dependencies. In order to help diagnose loading problems, consider setting the DYLD_PRINT_LIBRARIES environment variable: dlopen(libSystem.Native, 1): image not found
at Interop.Sys.GetUnixNamePrivate()
at Interop.Sys.GetUnixName()
at System.Runtime.InteropServices.RuntimeInformation.IsOSPlatform(OSPlatform osPlatform)
at Microsoft.DotNet.Tools.Uninstall.Shared.Utils.RuntimeInfo..cctor()
--- End of inner exception stack trace ---
at Microsoft.DotNet.Tools.Uninstall.Program.Main(String[] args)
Abort trap: 6

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.