Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: remove pyls and pyls_ms #1074

Merged
merged 1 commit into from
Jul 15, 2021
Merged

chore: remove pyls and pyls_ms #1074

merged 1 commit into from
Jul 15, 2021

Conversation

mjlbach
Copy link
Contributor

@mjlbach mjlbach commented Jul 15, 2021

  • pyls is unmaintained and has been continued as a community fork, pylsp
  • pyls_ms has been abandoned by microsoft in favor of the proprietary
    pylance/the less featureful (but open-source) pyright

If you really want these in your config for whatever reason, just copy/paste the configs as such (please don't):

 [[
https://github.com/palantir/python-language-server
`python-language-server`, a language server for Python.
The language server can be installed via `pipx install 'python-language-server[all]'`.
 ]]

require('lspconfig').pyls.setup {
    cmd = { 'pyls' },
    filetypes = { 'python' },
    root_dir = function(fname)
      return vim.fn.getcwd()
    end,
}

local util = require 'lspconfig/util'

[[
https://github.com/Microsoft/python-language-server
`python-language-server`, a language server for Python.
Requires [.NET Core](https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-install-script) to run. On Linux or macOS:

curl -L https://dot.net/v1/dotnet-install.sh | sh

`python-language-server` can be installed via [build](https://github.com/microsoft/python-language-server/blob/master/CONTRIBUTING.md#setup).
Set cmd to point to `Microsoft.Python.languageServer.dll`.

cmd = { "dotnet", "exec", "path/to/Microsoft.Python.languageServer.dll" };

If the `python` interpreter is not in your PATH environment variable, set the `InterpreterPath` and `Version` properties accordingly.

InterpreterPath = "path/to/python",
Version = "3.8"

This server accepts configuration via the `settings` key.
]]

require('lspconfig').pyls_ms.setup {
    filetypes = { 'python' },
    root_dir = function(fname)
      return util.find_git_ancestor(fname) or vim.loop.os_homedir()
    end,
    settings = {
      python = {
        analysis = {
          errors = {},
          info = {},
          disabled = {},
        },
      },
    },
    init_options = {
      interpreter = {
        properties = {
          InterpreterPath = '',
          Version = '',
        },
      },
      displayOptions = {},
      analysisUpdates = true,
      asyncStartup = true,
    },
  },
}

* pyls is unmaintained and has been continued as a community fork, pylsp
* pyls_ms has been abandoned by microsoft in favor of the proprietary
  pylance/the less featureful (but open-source) pyright
@mjlbach mjlbach merged commit 0429852 into neovim:master Jul 15, 2021
jdhao added a commit to jdhao/nvim-config that referenced this pull request Jul 15, 2021
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 neovim/nvim-lspconfig#1074.
See also palantir/python-language-server#935
and python-lsp/python-lsp-server#27.
Julian added a commit to Julian/dotfiles that referenced this pull request Jul 17, 2021
timokau added a commit to timokau/dotfiles that referenced this pull request Jul 17, 2021
The last update broke the neovim configuration since pyls was removed
from nvim-lspconfig. Pylsp is a maintained community fork. See [1].

[1] neovim/nvim-lspconfig#1074
@jan-xyz
Copy link
Contributor

jan-xyz commented Jul 22, 2021

The CONFIG.md still includes those, would you appreciate a contribution to remove it?
Never mind, I seem to have looked at an old state.

Julian added a commit to Julian/dotfiles that referenced this pull request Jun 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants