williamboman / nvim-lsp-installer

Further development has moved to https://github.com/williamboman/mason.nvim!
https://github.com/williamboman/mason.nvim
Apache License 2.0
2k stars 123 forks source link

Uninstalled LSP server still listed as configured and still shows warnings #513

Closed ghost closed 2 years ago

ghost commented 2 years ago

Problem description

After running :LspUninstall html the server is not shown in :LspInstallInfo under installed servers, as it should be. But it IS shown under configured servers when running :LspInfo. It also shows the error Spawning language server with cmd: 'vscode-html-language-server' failed. The language server is either not installed, missing from PATH, or not executable. How do I get rid of this error and fully remove the html server as it was before installation?

I have tried:

Neovim version (>= 0.6)

NVIM v0.6.1 Build type: Release LuaJIT 2.1.0-beta3 Compiled by void-buildslave@a-hel-fi

Features: +acl +iconv +tui

Operating system/version

Linux 5.15.24_1 (Void Linux x86_64 musl)

I've recently downloaded the latest plugin version of both nvim-lsp-installer and nvim-lspconfig

Affected language servers

html

Steps to reproduce

  1. type nvim [somefile].html

Actual behavior

get error Spawning language server with cmd: 'vscode-html-language-server' failed. The language server is either not installed, missing from PATH, or not executable.

Expected behavior

Open the file without errors.

LspInfo

Language client log: /home/tadej/.cache/nvim/lsp.log
Detected filetype:   html
0 client(s) attached to this buffer:
Other clients that match the filetype: html
Config: html
filetypes:         html
root directory:    NA
cmd:               vscode-html-language-server --stdio
cmd is executable: Unable to find executable. Please check your path and ensure the server is installed
autostart:         true
custom handlers:
Configured servers list: html, jdtls, tsserver, cssls, ccls, kotlin_language_server, bashls, texlab, jedi_language_server

Healthcheck

## nvim-lsp-installer report
  - OK: neovim version >= 0.6.0
  - WARNING: Go: not available
  - WARNING: Ruby: not available
  - WARNING: RubyGem: not available
  - WARNING: Composer: not available
  - WARNING: PHP: not available
  - WARNING: julia: not available
  - OK: sh: `Ok`
  - OK: tar: `tar (GNU tar) 1.34`
  - OK: gzip: `gzip 1.11`
  - OK: curl: `curl 7.81.0 (x86_64-unknown-linux-musl) libcurl/7.81.0 OpenSSL/1.1.1l zlib/1.2.11
      zstd/1.5.2 libssh2/1.9.0 nghttp2/1.46.0`
  - OK: wget: `GNU Wget 1.21.2 built on linux-musl.`
  - OK: python3: `Python 3.10.2`
  - OK: node: `v16.13.2`
  - OK: bash: `GNU bash, version 5.1.16(1)-release (x86_64-unknown-linux-musl)`
  - OK: java: `Ok`
  - OK: javac: `javac 11.0.12`
  - OK: npm: `8.5.2`
  - OK: pip3: `pip 22.0.3 from /usr/lib/python3.10/site-packages/pip (python 3.10)`

Screenshots or recordings

No response

williamboman commented 2 years ago

Hello! To completely "get rid" of a server that has already started and attached to one ore more buffers you'll need to restart neovim. You could also try stopping the server manually (either via :LspStop or through the vim.lsp.* APIs), which wouldn't necessitate a restart of neovim

williamboman commented 2 years ago

Also, make sure you're not callinglspconfig.html.setup {} anywhere in your config, I have a feeling this might be the culprit

ghost commented 2 years ago

It seems I've missed the lspconfig.html.setup {} part in my init.vim. Commenting it out solved my issue! Thanks for your help.