-
Notifications
You must be signed in to change notification settings - Fork 13
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
Inherit python.pythonPath from ST's project file? #380
Comments
Fwiw, that setting ( We can add a new venv finder in https://github.com/sublimelsp/LSP-pyright/blob/master/plugin/virtual_env/venv_finder.py (to find from ST project settings' My current suggestion would be https://github.com/sublimelsp/LSP-pyright#virtual-environments per project. |
Yes sorry, that was leftover from a previous project (I don't use Anaconda anymore) I'm sorry, I don't follow how I should use the instructions in the link you sent to solve this issue. I use conda environments, this is what my project file looks like:
The ideal scenario would be a way to tell this package to access the path defined in |
That seems to go too far imho. I will still say sublimelsp/LSP-pyright#virtual-environments |
Could you give me a small example of what I should do to use sublimelsp/LSP-pyright#virtual-environments to set up my conda environment as the default |
Create {
"venvPath": "/home/gabriel/miniconda3/envs",
"venv": "asteca"
} |
But that still requires me setting the environment in two separate places: ST's project and this JSON file. The goal was to avoid having to do this and have pyright lift the path from the project's file |
I am free to accept elegant PR(s). |
Imho, it makes more sense to implement a custom "build" (https://www.sublimetext.com/docs/build_systems.html#advanced-example) which auto honors Though I personally hardly use ST's build system. I just invoke a terminal and do what I want with a script (usually a Makefile). |
I set my python path per project using, e.g.:
Is there a way to have LSP-Pyright inherit this path? I just spent half a day debugging an issue only to discover that I had a different path set in LSP-Pyright's settings (
"python.pythonPath"
)Leaving it empty for automatic resolution does not work.
The text was updated successfully, but these errors were encountered: