You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Audit and potentially deprecate defaultInterpreterPath updates when Python Environments extension is active #25735
The Python extension currently updates the python.defaultInterpreterPath setting in multiple places throughout the codebase. When the Python Environments extension is installed and active (python.useEnvironmentsExtension: true), this creates potential conflicts and unexpected behavior since the Python Environments extension is intended to manage interpreter/environment selection independently.
Current Code Paths That Update defaultInterpreterPath
None of these code paths are currently guarded by useEnvExtension() to check if the Python Environments extension is active.
Deprecation Considerations
If we disable these updates when the Python Environments extension is active, defaultInterpreterPath would no longer be updated by the Python extension in the following scenarios (as these are the situations where it is updated for now)
VirtualEnvironmentPrompt: When a new virtual environment is detected in the workspace
ActivatedEnvironmentLaunch: When VS Code is launched from a terminal with an activated conda/venv environment
Create Environment command: After using the "Create Environment" command
Extension APIs: When other extensions call updateActiveEnvironmentPath() or setActiveEnvironment()
Further investigation is needed to understand the full impact on prompting behavior and auto-selection.
Questions
Do we want the Python extension to be able to edit defaultInterpreterPath when the Python Environments extension is active?
Does the Python Environments extension handle all the scenarios listed above?
Activity
eleanorjboyd commentedon Jan 14, 2026
This was generated by AI- but the primary question is
Do we want the Python extension (or envs ext) to be able to edit defaultInterpreterPath? Should the extension ever touch or update that setting?
my feeling is no because that is a fallback setting people can use but the better way is now the envs ext
Karthik Nadig (@karthiknadig) Anthony Kim (@anthonykim1) would appreciate you input on this basic question here (and you can read above for more context)
karthiknadig commentedon Jan 14, 2026
It should not, with a caveat. What should happen when user changes the environment? Should it update or not?
The problem here was that it was changing without user asking to change it.
Another thing. When envs extension is installed, python extension should not have control of this setting.