Description
Type: Bug
Behaviour
On windows, when I select a python venv (via Ctrl+MAj+P) or via python.defaultInterpreterPath value, the venv is not catched, and VS Code use the target of my venv python.exe symlink
Steps to reproduce:
-
on windows, create a venv with python.exe symbolic link instead of copy. You will need admin mode :
cd c:\temp
python -m venv --symlink my_venv -
create a new VS Code workspace with .vscode/settings.json with the content {"python.defaultInterpreterPath": "C:/temp/my_venv/Scripts/python.exe"}
-
Edit a python file, you will see that the "python locator" in the bottom blue bar is not your venv, but the default version of python of your system.
Diagnostic data
Output for Python
in the Output
panel 2025-06-23 23:42:54.243 [info] Native locator: Refresh started
2025-06-23 23:42:54.348 [info] Native locator: Refresh started
2025-06-23 23:42:54.411 [info] > pyenv which python
2025-06-23 23:42:54.411 [info] cwd: .
2025-06-23 23:42:54.584 [info] Native locator: Refresh finished in 333 ms
2025-06-23 23:42:54.597 [info] Active interpreter [c:\temp\carto\Report]: C:/temp/my_venv/Scripts/python.exe
2025-06-23 23:42:54.613 [info] Python interpreter path: ~\AppData\Local\Programs\Python\Python313\python.exe
2025-06-23 23:42:55.975 [info] Starting Jedi language server for Report.
2025-06-23 23:43:00.595 [info] Shell integration status changed, can confirm it's working.
Extension version: 2025.9.2025062001
VS Code version: Code 1.101.1 (18e3a1ec544e6907be1e944a94c496e302073435, 2025-06-18T13:35:12.605Z)
OS version: Windows_NT x64 10.0.26100
Modes:
- Python version (& distribution if applicable, e.g. Anaconda): 3.13.5
- Type of virtual environment used (e.g. conda, venv, virtualenv, etc.): System
- Value of the
python.languageServer
setting: Default
User Settings
languageServer: "Jedi"
Installed Extensions
Extension Name | Extension Id | Version |
---|---|---|
js-debug | ms- | 1.100.1 |
js-debug-companion | ms- | 1.1.3 |
python | ms- | 2025.9.2025062001 |
vscode-js-profile-table | ms- | 1.0.10 |
System Info
Item | Value |
---|---|
CPUs | Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz (8 x 1498) |
GPU Status | 2d_canvas: enabled canvas_oop_rasterization: enabled_on direct_rendering_display_compositor: disabled_off_ok gpu_compositing: enabled multiple_raster_threads: enabled_on opengl: enabled_on rasterization: enabled raw_draw: disabled_off_ok skia_graphite: disabled_off video_decode: enabled video_encode: enabled vulkan: disabled_off webgl: enabled webgl2: enabled webgpu: enabled webnn: disabled_off |
Load (avg) | undefined |
Memory (System) | 15.59GB (3.38GB free) |
Process Argv | --crash-reporter-id 43fa8202-045d-474d-8e14-cb506e4c1067 |
Screen Reader | no |
VM | 0% |
A/B Experiments
vsliv368:30146709
vspor879:30202332
vspor708:30202333
vspor363:30204092
vswsl492cf:30256860
vscod805:30301674
binariesv615:30325510
c4g48928:30535728
azure-dev_surveyone:30548225
962ge761:30959799
2e7ec940:31000449
pythontbext0:30879054
cppperfnew:31000557
dwnewjupyter:31046869
pythonrstrctxt:31112756
nativeloc1:31192215
5fd0e150:31155592
dwcopilot:31170013
6074i472:31201624
dwoutputs:31242946
customenabled:31248079
9064b325:31222308
copilot_t_ci:31333650
e5gg6876:31282496
pythoneinst12:31285622
bgtreat:31268568
4gafe986:31271826
c7cif404:31314491
pythonpulldiag:31325930
996jf627:31283433
pythonrdcb7cf:31303019
usemplatestapi:31297334
0aa6g176:31307128
7bj51361:31289155
747dc170:31275177
9hi5e907:31325879
aj953862:31281341
generatesymbolt:31295002
convertfstringf:31295003
pylancequickfixt:31329274
d784b465:31332230
i851h500:31332225
usemarketplace:31333563
id45c886:31333049
nes-diff-10:31333558
test-11-control:31334521