Error: OmniSharp fails to load
See original GitHub issueEnvironment data
dotnet --info
output:
.NET Core SDK (reflecting any global.json):
Version: 2.1.400
Commit: 8642e60a0f
Runtime Environment:
OS Name: Mac OS X
OS Version: 10.14
OS Platform: Darwin
RID: osx-x64
Base Path: /usr/local/share/dotnet/sdk/2.1.400/
Host (useful for support):
Version: 2.1.2
Commit: 811c3ce6c0
.NET Core SDKs installed:
2.1.3 [/usr/local/share/dotnet/sdk]
2.1.4 [/usr/local/share/dotnet/sdk]
2.1.200 [/usr/local/share/dotnet/sdk]
2.1.300 [/usr/local/share/dotnet/sdk]
2.1.301 [/usr/local/share/dotnet/sdk]
2.1.400 [/usr/local/share/dotnet/sdk]
.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.1.0 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.1.1 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.1.2 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.0 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.1.1 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.1.2 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.0.4 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
Microsoft.NETCore.App 2.0.5 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
Microsoft.NETCore.App 2.0.7 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.0 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.1 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.2 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
To install additional .NET Core runtimes or SDKs:
https://aka.ms/dotnet-download
VS Code version: 1.29.1 C# Extension version: 1.17.1
Steps to reproduce
Open C# project
Expected behavior
OmniSharp server starts up normally.
Actual behavior
Omnisharp fails during startup
Starting OmniSharp server at 12/8/2018, 3:25:30 PM
OmniSharp server started with Mono 5.16.0.
Path: /Users/alekseyusatov/.vscode/extensions/ms-vscode.csharp-1.17.1/.omnisharp/1.32.8/omnisharp/OmniSharp.exe
PID: 45088
[info]: OmniSharp.Stdio.Host
Starting OmniSharp on MacOS 10.14.1 (x64)
[info]: OmniSharp.Services.DotNetCliService
DotNetPath set to dotnet
Failed to launch 'mono' with args, '--version'
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
Located 1 MSBuild instance(s)
1: StandAlone 15.0 - "/Users/alekseyusatov/.vscode/extensions/ms-vscode.csharp-1.17.1/.omnisharp/1.32.8/omnisharp/msbuild/15.0/Bin"
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
MSBUILD_EXE_PATH environment variable set to '/Users/alekseyusatov/.vscode/extensions/ms-vscode.csharp-1.17.1/.omnisharp/1.32.8/omnisharp/msbuild/15.0/Bin/MSBuild.dll'
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
Registered MSBuild instance: StandAlone 15.0 - "/Users/alekseyusatov/.vscode/extensions/ms-vscode.csharp-1.17.1/.omnisharp/1.32.8/omnisharp/msbuild/15.0/Bin"
MSBuildExtensionsPath = /Library/Frameworks/Mono.framework/Versions/5.16.0/lib/mono/xbuild
BypassFrameworkInstallChecks = true
CscToolPath = /Users/alekseyusatov/.vscode/extensions/ms-vscode.csharp-1.17.1/.omnisharp/1.32.8/omnisharp/msbuild/15.0/Bin/Roslyn
CscToolExe = csc.exe
MSBuildToolsPath = /Users/alekseyusatov/.vscode/extensions/ms-vscode.csharp-1.17.1/.omnisharp/1.32.8/omnisharp/msbuild/15.0/Bin
TargetFrameworkRootPath = /Library/Frameworks/Mono.framework/Versions/5.16.0/lib/mono/xbuild-frameworks
System.TypeLoadException: Could not load type of field 'OmniSharp.MSBuild.ProjectManager:_queue' (11) due to: Could not load file or assembly 'System.Threading.Tasks.Dataflow, Version=4.5.24.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
at (wrapper managed-to-native) System.RuntimeType.GetPropertiesByName_native(System.RuntimeType,intptr,System.Reflection.BindingFlags,bool)
at System.RuntimeType.GetPropertiesByName (System.String name, System.Reflection.BindingFlags bindingAttr, System.Boolean icase, System.RuntimeType reflectedType) [0x0001b] in <98fac219bd4e453693d76fda7bd96ab0>:0
at System.RuntimeType.GetPropertyCandidates (System.String name, System.Reflection.BindingFlags bindingAttr, System.Type[] types, System.Boolean allowPrefixLookup) [0x00010] in <98fac219bd4e453693d76fda7bd96ab0>:0
at System.RuntimeType.GetProperties (System.Reflection.BindingFlags bindingAttr) [0x00000] in <98fac219bd4e453693d76fda7bd96ab0>:0
at System.Reflection.RuntimeReflectionExtensions.GetRuntimeProperties (System.Type type) [0x00006] in <98fac219bd4e453693d76fda7bd96ab0>:0
at System.Composition.TypedParts.Discovery.TypeInspector+<DiscoverPropertyExports>d__7.MoveNext () [0x00030] in <9aac21a4a3f24063b2b8b59143acddfc>:0
at System.Composition.TypedParts.Discovery.TypeInspector+<DiscoverExports>d__5.MoveNext () [0x000dc] in <9aac21a4a3f24063b2b8b59143acddfc>:0
at System.Composition.TypedParts.Discovery.TypeInspector.InspectTypeForPart (System.Reflection.TypeInfo type, System.Composition.TypedParts.Discovery.DiscoveredPart& part) [0x00061] in <9aac21a4a3f24063b2b8b59143acddfc>:0
at System.Composition.TypedParts.TypedPartExportDescriptorProvider..ctor (System.Collections.Generic.IEnumerable`1[T] types, System.Composition.Convention.AttributedModelProvider attributeContext) [0x00037] in <9aac21a4a3f24063b2b8b59143acddfc>:0
at System.Composition.Hosting.ContainerConfiguration.CreateContainer () [0x00042] in <9aac21a4a3f24063b2b8b59143acddfc>:0
at OmniSharp.CompositionHostBuilder.Build () [0x001f6] in <b0a7a1010bfe4b01af0da4ccbeac0c7a>:0
at OmniSharp.Stdio.Host..ctor (System.IO.TextReader input, OmniSharp.Stdio.Services.ISharedTextWriter writer, OmniSharp.IOmniSharpEnvironment environment, System.IServiceProvider serviceProvider, OmniSharp.CompositionHostBuilder compositionHostBuilder, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory, System.Threading.CancellationTokenSource cancellationTokenSource) [0x00057] in <5e8e2ad26ef5465098aa876c7f625e58>:0
at OmniSharp.Stdio.Driver.Program+<>c__DisplayClass0_1.<Main>b__1 () [0x00138] in <7c70c184a3894fbab0d699bc9b4ceac6>:0
at OmniSharp.CommandLineApplication+<>c__DisplayClass11_0.<OnExecute>b__0 () [0x0000b] in <b0a7a1010bfe4b01af0da4ccbeac0c7a>:0
at McMaster.Extensions.CommandLineUtils.CommandLineApplication.Execute (System.String[] args) [0x00039] in <344a1e8cd6594b17b1e01f8df6ae8827>:0
at OmniSharp.CommandLineApplication.Execute (System.Collections.Generic.IEnumerable`1[T] args) [0x00042] in <b0a7a1010bfe4b01af0da4ccbeac0c7a>:0
at OmniSharp.Stdio.Driver.Program+<>c__DisplayClass0_0.<Main>b__0 () [0x00028] in <7c70c184a3894fbab0d699bc9b4ceac6>:0
at OmniSharp.HostHelpers.Start (System.Func`1[TResult] action) [0x0001c] in <b0a7a1010bfe4b01af0da4ccbeac0c7a>:0
Issue Analytics
- State:
- Created 5 years ago
- Comments:10
Top Results From Across the Web
Omnisharp fails to load · Issue #3545 - GitHub
Issue Description. Omnisharp fails to load. Steps to Reproduce. Open dotnet project and look at log. Expected Behavior.
Read more >Omnisharp with VS Code: Error, "Project Loading Failed"
After I followed his video, It fixed my loading problem. On your C# exstions under the gear pick "Extension Settings" then in the...
Read more >OmniSharp fails to load properly in Visual Studio Code
Start(Func`1 action) in D:\a\1\s\src\OmniSharp.Host\HostHelpers.cs:line 30 [ERROR] Error: OmniSharp server load timed out. Use the 'omnisharp ...
Read more >VS Code error C# and .NET Core (section 1) - Ask - GameDev.tv
ProjectManager Failed to load project file ... \ms-dotnettools.csharp-1.23.9\.omnisharp\1.37.8-beta.15\.msbuild\Current\Bin\Microsoft.
Read more >Autocomplete in unity isn't working : r/Unity3D - Reddit
[warn]: OmniSharp.MSBuild.ProjectManager. Failed to load project file '/Users/myname/Unity Projects/FP Game/Assembly-CSharp.csproj'.
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
In my case the problem was solved by installing the msbuild package.
Yes,
useGlobalMono
set tonever
solves the problem.I don’t know what’s the exact problem with my global mono. I don’t use it myself for anything but I can run it using terminal. I’ve tried wiping it out and reinstall the latest one. Unfortunately, the problem hasn’t gone if I set
useGlobalMono
forauto
oralways
.