microsoft / microsoft/vscode-python-debugger

Extension searching for package.json in wrong directory.

Open
#686 7 comments 2 reactions 1 assignee View on GitHub

Nobody has claimed this yet.

triage-needed
Dominant language
TypeScript
Stars
180
Forks
126
Avg merge
2d 3h
Merged PRs (30d)
3

Description

Type: Bug

Behaviour

Unable to read file 'c:\Users\UserName.vscode\extensions\ms-python.python-2025.2.0-win32-x64\package.json' 
(Error: Unable to resolve nonexistent file 'c:\Users\UserName.vscode\extensions\ms-python.python-2025.2.0-win32-x64\package.json')

There seems to be a backward slash missing between UserName and .vscode.
package is json is present at
c:\Users\UserName\.vscode\extensions\ms-python.python-2025.2.0-win32-x64\package.json

Steps to reproduce:

  1. Installing VSCode Extension.

Diagnostic data

Output for Python in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python)

XXX

Behaviour

Unable to debug python code.

Diagnostic data

Output for Python in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python)

2025-03-18 10:44:08.645 [warning] Dir "c:\SubratKatiyar\GitWorkDir\system_builder\.pixi\envs" is not watchable (directory does not exist)
2025-03-18 10:44:08.688 [info] > pyenv which python
2025-03-18 10:44:08.688 [info] cwd: .
2025-03-18 10:44:08.705 [info] > .\.venv\Scripts\python.exe -I ~\.vscode\extensions\ms-python.python-2025.2.0-win32-x64\python_files\get_output_via_markers.py ~\.vscode\extensions\ms-python.python-2025.2.0-win32-x64\python_files\interpreterInfo.py
2025-03-18 10:44:09.365 [info] Python interpreter path: .\.venv\Scripts\python.exe
2025-03-18 10:44:10.357 [info] Starting Pylance language server.
2025-03-18 10:44:39.113 [info] Starting Environment refresh
2025-03-18 10:44:39.114 [info] Searching for windows registry interpreters
2025-03-18 10:44:39.114 [info] Searching windows known paths locator
2025-03-18 10:44:39.116 [info] Searching for pyenv environments
2025-03-18 10:44:39.116 [info] Searching for conda environments
2025-03-18 10:44:39.116 [info] Searching for global virtual environments
2025-03-18 10:44:39.116 [info] Searching for custom virtual environments
2025-03-18 10:44:39.116 [info] Searching for windows store envs
2025-03-18 10:44:39.120 [info] > conda info --json
2025-03-18 10:44:39.122 [info] > hatch env show --json
2025-03-18 10:44:39.122 [info] cwd: .
2025-03-18 10:44:39.127 [info] pyenv is not installed
2025-03-18 10:44:39.127 [info] Finished searching for pyenv environments: 12 milliseconds
2025-03-18 10:44:39.141 [info] Finished searching for custom virtual envs: 25 milliseconds
2025-03-18 10:44:39.141 [info] Finished searching for windows store envs: 25 milliseconds
2025-03-18 10:44:39.142 [info] Finished searching for global virtual envs: 27 milliseconds
2025-03-18 10:44:39.152 [info] Finished searching windows known paths locator: 39 milliseconds
2025-03-18 10:44:39.174 [info] > ~\AppData\Local\Programs\Python\Python311\python.exe -I ~\.vscode\extensions\ms-python.python-2025.2.0-win32-x64\python_files\get_output_via_markers.py ~\.vscode\extensions\ms-python.python-2025.2.0-win32-x64\python_files\interpreterInfo.py
2025-03-18 10:44:40.173 [info] Finished searching for windows registry interpreters: 1086 milliseconds
2025-03-18 10:44:40.175 [info] Environments refresh paths discovered (event): 1088 milliseconds
2025-03-18 10:44:40.175 [info] Environments refresh paths discovered: 1088 milliseconds
2025-03-18 10:44:40.177 [info] Environments refresh finished (event): 1090 milliseconds
2025-03-18 10:44:40.180 [info] Environment refresh took 1094 milliseconds
2025-03-18 10:44:46.127 [info] Send text to terminal: c:/SubratKatiyar/GitWorkDir/system_builder/.venv/Scripts/activate.bat

Extension version: 2025.2.0
VS Code version: Code 1.97.0 (33fc5a94a3f99ebe7087e8fe79fbe1d37a251016, 2025-02-04T22:41:26.688Z)
OS version: Windows_NT x64 10.0.22631
Modes:

  • Python version (& distribution if applicable, e.g. Anaconda): 3.11.4
  • Type of virtual environment used (e.g. conda, venv, virtualenv, etc.): Venv
  • Value of the python.languageServer setting: Default
User Settings


languageServer: "Pylance"

experiments
• enabled: false

Installed Extensions
Extension Name Extension Id Version
cmake-tools ms- 1.20.53
copilot Git 1.277.0
copilot-chat Git 0.24.1
cpptools ms- 1.23.6
cpptools-extension-pack ms- 1.3.1
cpptools-themes ms- 2.0.0
csdevkit ms- 1.16.6
csharp ms- 2.63.32
debugpy ms- 2025.4.1
js-debug ms- 1.97.0
js-debug-companion ms- 1.1.3
python ms- 2025.2.0
remote-explorer ms- 0.4.3
remote-server ms- 1.5.2
remote-ssh ms- 0.118.0
remote-ssh-edit ms- 0.87.0
remote-wsl ms- 0.88.5
vscode-dotnet-runtime ms- 2.2.8
vscode-js-profile-table ms- 1.0.10
vscode-pylance ms- 2025.3.2
System Info
Item Value
CPUs 13th Gen Intel(R) Core(TM) i7-13800H (20 x 2918)
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) 31.62GB (16.77GB free)
Process Argv --crash-reporter-id 42f2e52a-9ffd-461a-bda0-8f58d623a694
Screen Reader no
VM 0%
A/B Experiments
vsliv368:30146709
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscod805cf:30301675
binariesv615:30325510
py29gd2263:31024239
c4g48928:30535728
azure-dev_surveyone:30548225
962ge761:30959799
h48ei257:31000450
pythontbext0:30879054
cppperfnew:31000557
dwnewjupyter:31046869
nativerepl1:31139838
pythonrstrctxt:31112756
nativeloc2:31192216
iacca1:31171482
5fd0e150:31155592
dwcopilot:31170013
6074i472:31201624
dwoutputs:31242946
customenabled:31248079
hdaa2157:31222309
copilot_t_ci:31222730
f5992895:31259995
jda6j935:31233686
pythoneinst12cf:31262606
bgtreat:31262795
fh1c7952:31258891
6h6a5794:31261449
5b33h341:31253271
31787653:31262186
0339e702:31259951

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.