Skip to content

set the environment for the lsp server #496

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

Closed
lmascelli opened this issue Dec 4, 2023 · 2 comments
Closed

set the environment for the lsp server #496

lmascelli opened this issue Dec 4, 2023 · 2 comments

Comments

@lmascelli
Copy link

hi,
i'm sorry if lots of people already asked this question and i'll ask it again but with all the solutions i've read i still have not figured out how to correctly set that. The situation is the following:
i'm working on an embeddable python environment, obtained from the embeddable python distribution, extracted from the archive, not a virtual env, with a library i made and installed in that environment. the code runs without issues.
That said, how can i set the pylsp server to use THAT environment?

@ccordoba12
Copy link
Member

Hey @lmascelli, thanks for reporting. This can be done by setting the pylsp.plugins.jedi.environment configuration option to the path of your Python executable.

All configuration options for the server can be found here:

https://github.com/python-lsp/python-lsp-server/blob/develop/CONFIGURATION.md

@ilan-schemoul
Copy link

No, pylint does not seem to use jedi's environement variable

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

No branches or pull requests

3 participants