Some LSPs (e.g. jedi-language-server) only find 3rd party sources if they are present in the python venv created by mason #1448
Unanswered
liviu-liviu
asked this question in
Q&A
Replies: 1 comment
-
The jedi-language-server should automatically "detect" the virtual environment. For this to work, I presume you'll have to activate the virtual environment either before launching Neovim, or somehow do it inside Neovim. Also see #1276 (comment) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I've installed the jedi-language-server via mason. It works well when I search for definitions located inside the project but fails to find definitions in 3rd party source code (e.g. PyTorch).
I'm thinking this happens because mason has installed the LSP under a virtual environment and only finds packages that exist there. ~/.local/share/nvim/mason/packages/jedi-language-server/venv
It seems strange to need to install all my project dependencies a second time under this venv. But if I do, the LSP starts finding the missing definitions.
Is there a way to avoid having two sets of the same dependencies installed, one for my project and the other for the LSP venv?
Beta Was this translation helpful? Give feedback.
All reactions