Skip to content

Cannot select venv environment #1718

Description

Environment data

Windows

Version: 1.133.0 (user setup)
Commit: a5b500951314efd502d07465bd138dfbd714a960
Date: 2026-08-11T22:14:08Z
Electron: 42.8.0
ElectronBuildId: 14845705
Chromium: 148.0.7778.280
Node.js: 24.18.0
V8: 14.8.178.38-electron.0
@github/copilot: 1.0.79-6
@github/copilot-sdk: 1.0.9
OS: a5b500951314efd502d07465bd138dfbd714a960

  • Python Environments extension version: 1.36.0
  • Python extension (ms-python.python) version: 1.36.0
  • VS Code version (Help → About): 1.1.33.0
  • OS and version: Windows 11
  • Python version (& distribution if applicable, e.g. Anaconda): 3.13
  • Environment manager in use (venv / conda / pyenv / poetry / pipenv / system / uv / other): venv
  • Shell (bash / zsh / fish / pwsh / cmd / other): cmd
  • Remote / container scenario (none / WSL / SSH Remote / Dev Container / Codespaces): none
  • Workspace type (single folder / multi-root / mono-repo): single folder
  • Is this a regression? If yes, last known working extension version: unknown

Repro Steps

Try to select a venv environment outside of the workspace folder.

Expected behavior

The Python interpreter is selected

Actual behavior

Error message:

Selected file is not a valid Python interpreter: c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe

And it's falling back to the global Python installation instead.

Logs

Tried this several time, starting 09:49 is with trace level.

2026-08-18 09:51:37.254 [debug] Checking venv (ms-python.python:venv) for c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.255 [debug] Environment search directories: 2 paths
2026-08-18 09:51:37.255 [debug] [pet] configure: No changes detected, skipping configuration update.
2026-08-18 09:51:37.287 [error] [pet] �[2m 784.057678400s�[0m �[31mERROR�[0m �[2mpet_python_utils::env�[0m�[2m:�[0m Python Execution for "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe" produced an output "" without a separator
�[2m 784.057767700s�[0m �[31mERROR�[0m �[2mpet::jsonrpc�[0m�[2m:�[0m Failed to resolve env "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe", returning discovered env PythonEnvironment { display_name: None, name: None, executable: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"), kind: Some(Venv), version: None, prefix: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv"), manager: None, project: None, arch: None, symlinks: Some(["c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"]), error: None }

2026-08-18 09:51:37.288 [info] Resolved Python Environment c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.288 [debug] Failed to resolve venv env "c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe": Error: Invalid python info: {"arch":null,"displayName":null,"error":null,"executable":"c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe","kind":"Venv","manager":null,"name":null,"prefix":"c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv","project":null,"symlinks":["c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"],"version":null}
2026-08-18 09:51:37.290 [debug] Environment search directories: 2 paths
2026-08-18 09:51:37.290 [debug] [pet] configure: No changes detected, skipping configuration update.
2026-08-18 09:51:37.322 [error] [pet] �[2m 784.092843600s�[0m �[31mERROR�[0m �[2mpet_python_utils::env�[0m�[2m:�[0m Python Execution for "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe" produced an output "" without a separator
�[2m 784.092869400s�[0m �[31mERROR�[0m �[2mpet::jsonrpc�[0m�[2m:�[0m Failed to resolve env "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe", returning discovered env PythonEnvironment { display_name: None, name: None, executable: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"), kind: Some(Venv), version: None, prefix: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv"), manager: None, project: None, arch: None, symlinks: Some(["c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"]), error: None }

2026-08-18 09:51:37.323 [info] Resolved Python Environment c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.325 [debug] Manager venv (ms-python.python:venv) cannot handle c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.325 [debug] Checking PyEnv (ms-python.python:pyenv) for c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.325 [debug] Environment search directories: 2 paths
2026-08-18 09:51:37.325 [debug] [pet] configure: No changes detected, skipping configuration update.
2026-08-18 09:51:37.358 [error] [pet] �[2m 784.128602000s�[0m �[31mERROR�[0m �[2mpet_python_utils::env�[0m�[2m:�[0m Python Execution for "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe" produced an output "" without a separator
�[2m 784.128635200s�[0m �[31mERROR�[0m �[2mpet::jsonrpc�[0m�[2m:�[0m Failed to resolve env "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe", returning discovered env PythonEnvironment { display_name: None, name: None, executable: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"), kind: Some(Venv), version: None, prefix: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv"), manager: None, project: None, arch: None, symlinks: Some(["c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"]), error: None }

2026-08-18 09:51:37.358 [info] Resolved Python Environment c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.359 [debug] Checking Pipenv (ms-python.python:pipenv) for c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.360 [debug] Environment search directories: 2 paths
2026-08-18 09:51:37.361 [debug] [pet] configure: No changes detected, skipping configuration update.
2026-08-18 09:51:37.423 [error] [pet] �[2m 784.193347300s�[0m �[31mERROR�[0m �[2mpet_python_utils::env�[0m�[2m:�[0m Python Execution for "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe" produced an output "" without a separator
�[2m 784.193374500s�[0m �[31mERROR�[0m �[2mpet::jsonrpc�[0m�[2m:�[0m Failed to resolve env "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe", returning discovered env PythonEnvironment { display_name: None, name: None, executable: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"), kind: Some(Venv), version: None, prefix: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv"), manager: None, project: None, arch: None, symlinks: Some(["c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"]), error: None }

2026-08-18 09:51:37.427 [info] Resolved Python Environment c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.428 [debug] Checking Poetry (ms-python.python:poetry) for c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.429 [debug] Environment search directories: 2 paths
2026-08-18 09:51:37.429 [debug] [pet] configure: No changes detected, skipping configuration update.
2026-08-18 09:51:37.461 [error] [pet] �[2m 784.232215300s�[0m �[31mERROR�[0m �[2mpet_python_utils::env�[0m�[2m:�[0m Python Execution for "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe" produced an output "" without a separator
�[2m 784.232244000s�[0m �[31mERROR�[0m �[2mpet::jsonrpc�[0m�[2m:�[0m Failed to resolve env "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe", returning discovered env PythonEnvironment { display_name: None, name: None, executable: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"), kind: Some(Venv), version: None, prefix: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv"), manager: None, project: None, arch: None, symlinks: Some(["c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"]), error: None }

2026-08-18 09:51:37.462 [info] Resolved Python Environment c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.463 [debug] Checking Global (ms-python.python:system) for c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.464 [debug] Environment search directories: 2 paths
2026-08-18 09:51:37.464 [debug] [pet] configure: No changes detected, skipping configuration update.
2026-08-18 09:51:37.495 [error] [pet] �[2m 784.266021000s�[0m �[31mERROR�[0m �[2mpet_python_utils::env�[0m�[2m:�[0m Python Execution for "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe" produced an output "" without a separator
�[2m 784.266048100s�[0m �[31mERROR�[0m �[2mpet::jsonrpc�[0m�[2m:�[0m Failed to resolve env "c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe", returning discovered env PythonEnvironment { display_name: None, name: None, executable: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"), kind: Some(Venv), version: None, prefix: Some("c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv"), manager: None, project: None, arch: None, symlinks: Some(["c:\\svn\\modules\\reporting\\trunk\\lrs_lra\\venv\\Scripts\\python.exe"]), error: None }

2026-08-18 09:51:37.496 [info] Resolved Python Environment c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe
2026-08-18 09:51:37.497 [warning] Unable to handle c:\svn\modules\reporting\trunk\lrs_lra\venv\Scripts\python.exe

Metadata

Metadata

Labels

area-environmentEnvironment, interpreter related issues.bugIssue identified by VS Code Team member as probable bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions