coc-omnisharp: Error on Startup
CocInfo
`## versions
vim version: NVIM v0.4.0-1256-g564d415d2 node version: v11.15.0 coc.nvim version: 0.0.72-22daa03a7d term: xterm-kitty platform: linux
Messages
[coc.nvim] error: UnhandledRejection: Command “/home/erik/.config/coc/extensions/node_modules/coc-omnisharp/omnisharp/OmniSharp” of cs is not executable: Error: not found: /home/erik/.config/coc/extensions/node_modules/coc-omnisharp/omnisharp/OmniSharp Error: Command “/home/erik/.config/coc/extensions/node_modules/coc-omnisharp/omnisharp/OmniSharp” of cs is not executable: Error: not found: /home/erik/.config/coc/extensions/node_modules/coc-omnisharp/omnisharp/OmniSharp at LanguageClient.createMessageTransports (/home/erik/.local/share/nvim/plugged/coc.nvim/build/index.js:65458:23)
Output channel: prettier
Output channel: highlight
[Info - 9:14:05 AM] Highlight server running in node v11.15.0
Output channel: cs
[Error - 9:14:13 AM] Starting client failed: Error: Command “/home/erik/.config/coc/extensions/node_modules/coc-omnisharp/omnisharp/OmniSharp” of cs is not executable: Error: not found: /home/erik/.config/coc/extensions/node_modules/coc-omnisharp/omnisharp/OmniSharp at LanguageClient.createMessageTransports (/home/erik/.local/share/nvim/plugged/coc.nvim/build/index.js:65458:23)`
Steps taken.
- Open neovim at project solution root
- Open up a cs file in a project that is part of the solution
At first I thought it was a conflict due to not disabling the omnisharp server startup from vim-omnisharp. But I got the same error when configuring that to not start up its omnisharp server.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 1
- Comments: 33 (21 by maintainers)
Same issue, on Arch
I was able to get to a different error by copying a
runtimeconfig.json
file from a hello world project’s bin:the second error is:
Edit: Launching
OmniSharp.exe
withmono
from the command line doesn’t show any errors, so maybe try that?Edit 2: setting
"omnisharp.useDotnet": false,
in:CocConfig
works… Somewhat…@mihaelartz don’t worry. You’re helping a lot by testing it out 😃
Please try 0.0.7 – I’ve added an option to specify how to start omnisharp – defaults to
dotnet
– make sure you have dotnet core installed.hmm, autocompletion started to work after some time:
Yeah, it doesn’t look like Omnisharp is helping a lot here
sorry for the trouble, some dumb mistakes… please try 0.0.5
@yatli this line: https://github.com/yatli/coc-omnisharp/blob/master/src/client/platform.ts#L76
change to:
const omnisharpDirectory = path.join(__dirname, "..", "..", "omnisharp/omnisharp")
and, mono must be installed manually via https://www.mono-project.com/download/stable/
after this changes, i don’t get any errors, but completion is week, i don’t get completions for class methods, attributes, namespaces…
you mean, for Linux it’s not a self-contained
dotnet
application?