Allow disabling of interpreter auto-selection #16153
Replies: 5 comments
-
Hi @AaronNBrock, The environment auto-selection proceeds as follows:
If you want to get the "Select Python Environment" prompt on the status bar, you can set |
Beta Was this translation helpful? Give feedback.
-
Hey @kimadeline, I updating the the setting: {
"python.defaultInterpreterPath": " "
} However it's still automatically selecting a the other environment. Also, is the functionality you describe here documented anywhere? Thanks~ |
Beta Was this translation helpful? Give feedback.
-
Hi @AaronNBrock, thank you for your patience! This setting only works if you're in the DeprecatePythonPath experiment. Try adding this to your global "python.experiments.optInto": [
"DeprecatePythonPath - experiment"
], It is documented in the wiki. However since your ask is to find a way to disable interpreter auto-selection, I am going to switch this to a feature request and mark this issue as "needs decision" to make sure we have a conversation about your idea. We plan to leave this feature request open for at least a month to see how many 👍 votes your idea gets to help us make our decision, so feel free to upvote the initial post to help us prioritize it. |
Beta Was this translation helpful? Give feedback.
-
Hey @AaronNBrock, we converted the issue to a discussion item as this is a feature request. Would you mind elaborating why do you want to disable interpreter auto selection? You can define a default interpreter for your workspaces, but I'm not sure why you would not want to have an environment selected at all to your workspaces. |
Beta Was this translation helpful? Give feedback.
-
Moved to #17228 |
Beta Was this translation helpful? Give feedback.
-
Environment data
python.languageServer
setting: Not Set[NOTE: If you suspect that your issue is related to the Microsoft Python Language Server (
python.languageServer: 'Microsoft'
), please download our new language server Pylance from the VS Code marketplace to see if that fixes your issue]Background
Nowhere in my vscode settings (user, remote, or workspace) do I define a
python.pythonPath
(norpython.defaultInterpreterPath
), the setting is completely empty:Expected behaviour
Newly created projects should have no interpreter & vscode should show
Select Python Interpreter
on the statusbarActual behaviour
Newly created projects select my conda project
auth0-python-web-app
(an environment from a unrelated project).Steps to reproduce:
[NOTE: Self-contained, minimal reproducing code samples are extremely helpful and will expedite addressing your issue]
This is for me to reproduce
File
>Open Folder...
> Select newly created folder*.py
auth0-python-web-app
environmentOther notes
auth0-python-web-app
), vscode will start autoselecting a different conda environment. I can't figure out how it determines which one it selects.Beta Was this translation helpful? Give feedback.
All reactions