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

Add support to pylsp #47

Closed
martini97 opened this issue Aug 9, 2021 · 0 comments · Fixed by #64
Closed

Add support to pylsp #47

martini97 opened this issue Aug 9, 2021 · 0 comments · Fixed by #64

Comments

@martini97
Copy link

I get some warnings about pyls being deprecated:

Warning (emacs): The palantir python-language-server (pyls) is unmaintained; a maintained fork is the python-lsp-server (pylsp) project; you can install it with pip via: pip install python-lsp-server Disable showing Disable logging

It would be nice to add support to the pylsp server as well, so far I got it working with:

(use-package lsp-docker
  :straight t
  :config
  (defvar lsp-docker-client-packages
    '(lsp-css lsp-clients lsp-bash lsp-go lsp-html lsp-pylsp ;; lsp-pyls
	      lsp-dockerfile lsp-javascript lsp-terraform))

  (setq lsp-docker-client-configs
	'((:server-id bash-ls :docker-server-id bashls-docker :server-command "bash-language-server start")
	  (:server-id css-ls :docker-server-id cssls-docker :server-command "css-languageserver --stdio")
	  (:server-id dockerfile-ls :docker-server-id dockerfilels-docker :server-command "docker-langserver --stdio")
	  (:server-id gopls :docker-server-id gopls-docker :server-command "gopls")
	  (:server-id html-ls :docker-server-id htmls-docker :server-command "html-languageserver --stdio")
	  ;; (:server-id pyls :docker-server-id pyls-docker :server-command "pyls")
	  (:server-id pylsp :docker-server-id pylsp-docker :server-command "pylsp" :docker-image-id "martini97/lsp-docker-langservers" :docker-container-name "martini97-lsp-pylsp")
	  (:server-id ts-ls :docker-server-id tsls-docker :server-command "typescript-language-server --stdio")))

  (let ((projects-dir (expand-file-name "~/Projects")))
    (lsp-docker-init-clients
      :path-mappings `((,projects-dir . "/projects"))
      :client-packages lsp-docker-client-packages
      :client-configs lsp-docker-client-configs)))

On my Emacs config and using this Docker image:

# Local Variables:
# docker-image-name: "martini97/lsp-docker-langservers"
# End:

FROM emacslsp/lsp-docker-langservers

RUN pip3 install 'python-lsp-server[all]'

But it would be nice to have it added to the package.

jinnovation added a commit to jinnovation/lsp-docker that referenced this issue Dec 25, 2022
Closes emacs-lsp#47.

The "original" Python language server, `python-language-server` -- originally
authored by Palantir -- is no longer maintained; see
palantir/python-language-server#935, as well as the fact that there's been no
development activity since 2020.

This PR updates all references to point to the community-forked
`python-lsp-server` (https:/python-lsp/python-lsp-server).
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 a pull request may close this issue.

1 participant