1
0
mirror of https://github.com/jdhao/nvim-config.git synced 2025-06-08 14:14:33 +02:00

Use pylsp instead of pyls

It seems that pyls, the original python language server has lost its
momentum, and pylsp is a community driven fork of pyls. So
nvim-lspconfig has dropped support for pyls in https://github.com/neovim/nvim-lspconfig/pull/1074.
See also https://github.com/palantir/python-language-server/issues/935
and https://github.com/python-lsp/python-lsp-server/issues/27.
This commit is contained in:
jdhao
2021-07-15 23:33:02 +08:00
parent 4689c4b22f
commit ffb0601aca
3 changed files with 13 additions and 10 deletions

View File

@@ -57,26 +57,29 @@ capabilities.textDocument.completion.completionItem.snippetSupport = true
local lspconfig = require("lspconfig")
lspconfig.pyls.setup{
lspconfig.pylsp.setup{
on_attach = on_attach,
settings = {
pyls = {
pylsp = {
plugins = {
flake8 = {enabled = false},
pylint = {enabled = true, executable = "pylint"},
pyflakes = {enabled = false},
pycodestyle = {enabled = false},
jedi_completion = {fuzzy = true},
pyls_isort = {enabled = true},
pyls_mypy = {enabled = true}
pylsp_mypy = {enabled = true}
}
}
},
flags = {
debounce_text_changes = 500,
debounce_text_changes = 200,
}
}
-- lspconfig.pyright.setup{
-- on_attach = on_attach,
-- }
lspconfig.clangd.setup{
on_attach = on_attach,
capabilities = capabilities,