Ionide-vim icon indicating copy to clipboard operation
Ionide-vim copied to clipboard

RPC errors when trying to connect to the LSP server

Open OmanF opened this issue 2 years ago • 2 comments

Describe the bug When starting an F# file, or running an operation that requires the LSP server being queried, I get RPC[Error] of varying types:

  1. When starting a file, the error is it couldn't find the last non-whitespace char
  2. When trying to comment a line using Tim Pope's vim-commentary plugin (which I've bound to gcc, for example), the error is it can't find a triggering char.
  3. For auto-complete dropdown, it's a coin toss: sometimes I get the same results as I get using Ionide for VSCode, and sometimes I get very partial results.

To Reproduce As indicated in the description, either open an F# or perform an operation that requires LSP server interaction.

Expected behaviour No RPC errors so the LSP communication is fluid and I get the full benefits of using the plugin.

Screenshots

ksnip_20230729-103018

ksnip_20230729-103102

Environment (please complete the following information):

  • OS: ArchLinux (kept up-to-date on a daily basis, all packages are at the latest available on AUR)
  • Vim / Neovim version: NVIM 0.9.1, Release, LuaJIT 2.1.0-beta3
  • dotnet SDK version: 7.0.306
  • mono / .Net Framework version: N/A (on Linux, using dotnet)

Additional context I don't know if it's important, but I've fsautocomplete installed globally, version 0.61.1 and am starting the plugin in NVIM via the following call:

let g:fsharp#fsautocomplete_command = [ "fsautocomplete" ]
let g:fsharp#lsp_codelens = 0

OmanF avatar Jul 29 '23 08:07 OmanF

@baronfel is this another case of missing more places to return null instead of an error?

TheAngryByrd avatar Aug 09 '23 00:08 TheAngryByrd

Yeah, I think so - I bet we could search for these errors and return more gracefully!

baronfel avatar Aug 09 '23 01:08 baronfel