Skip to content

Commit 33c8016

Browse files
authored
Do not update global python.defaultInterpreterPath when a runtime starts (#5054)
Addresses #4552 I want to point out #3255 where we _added_ updating the path in the workspace. I suspect (???) that updating the setting globally was never the right thing to do; this was added in the massive posit-dev/positron-python#413 for multi-session support. This PR does not address how updating the `python.defaultInterpreterPath` user setting starts Python. I have [some more notes here](#4552 (comment)) and we can open a followup PR if folks think this is a problem. It seems mostly like intended/inherited behavior from upstream to me. ### QA Notes - Open a workspace and have R only running. - Open an additional workspace and have R only running. - Start a Python runtime in the second workspace via the top bar. You should _not_ see any Python runtime start in the first workspace/window. We should still see the correct behavior for #3169 and #3255. I don't think we can write a useful unit test for this and we don't currently have multi-workspace tests. It might be worth putting that (smoke tests for multiple workspaces) on the todo list eventually but certainly seems like an advanced move.
1 parent dd5b401 commit 33c8016

File tree

1 file changed

+0
-1
lines changed
  • extensions/positron-python/src/client/positron

1 file changed

+0
-1
lines changed

extensions/positron-python/src/client/positron/session.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,6 @@ export class PythonRuntimeSession implements positron.LanguageRuntimeSession, vs
277277
await this._installIpykernel();
278278

279279
// Update the active environment in the Python extension.
280-
this._interpreterPathService.update(undefined, vscode.ConfigurationTarget.Global, this.interpreter.path);
281280
this._interpreterPathService.update(
282281
undefined,
283282
vscode.ConfigurationTarget.WorkspaceFolder,

0 commit comments

Comments
 (0)