Ive set up remote lsp-mode with tramp and pylsp server. While the server does start when I open a remote py file, many server features such as auto completions, code format, references dont work.
Here is my setup
(eval-when-compile
(require 'use-package))
(use-package lsp-mode
:hook (python-mode . lsp)
:config
(lsp-register-client
(make-lsp-client :new-connection (lsp-tramp-connection "pylsp")
:major-modes '(python-mode)
:remote? t
:server-id 'pyls-remote)))
;; Set tramp remote path
(add-to-list 'load-path "/usrlocal/share/emacs/site-lisp/")
(require 'tramp)
(add-to-list 'Info-directory-list "/usr/local/share/info/")
(add-to-list 'tramp-remote-path "~/envs/general/bin")
(add-to-list 'tramp-remote-path 'tramp-own-remote-path)
(use-package company
:ensure t
:diminish company-mode
:hook (prog-mode . global-company-mode)
:commands (company-mode company-indent-or-complete-common)
:init)