I am a Neovim user, and I am trying out Emacs.
I recently started with doom emacs, it feels pretty good. However, one issue I am facing is that pyright works very slow. I know that it is an issue with pyright, which I faced with Neovim also.
However, I made it faster for my use-case by changing some settings. Neovim allows to have these settings in the setup function for LSP. I was trying to figure out how do I change these settings with doom emacs. Pyright docs suggest to have these settings in pyrightconfig.json.
I think this is more of a pyright issue, but feel like somebody might have already solved it.
You can put these lines to your config:
(after! python (setq lsp-pyright-multi-root nil lsp-pyright-use-library-code-for-types nil))
Press
Spc-h-v
and start typing lsp-pyright, you will see all available settings (you have to load lsp-pyright before it).Eglot is really awful when it comes to dynamic configs like workspace config and initialization option. I really went so far as using environment variable and a shell script for using clangd to support switching cmake binary dir. It’s so much easier with vim.
In case of python, I stick with jedi-language-server for now. When I figure out how to use pyright, I might come back here and comment again.