microsoft/debugpy

cannot debug python file which can run fine from terminal

Cameron-Whittle opened this issue · 0 comments

Type: Bug

Behaviour

Pressing f5 and using the auto generated launch.json file fails to start with the pop up window "Launcher[1] disconnected unexpectedly" and the option to open 'launch.json'

Steps to reproduce:

A basic python program, nothing special hello world will do, on a fresh install of the python extension. press 5

Diagnostic data

command run in Python Debug console by F5

PS C:\Users\Cameron\Documents\advent_of_code> ^C
PS C:\Users\Cameron\Documents\advent_of_code>
PS C:\Users\Cameron\Documents\advent_of_code> c:; cd 'c:\Users\Cameron\Documents\advent_of_code'; & 'c:\Users\Cameron\Documents\advent_of_code.venv\Scripts\python.exe' 'c:\Users\Cameron.vscode\extensions\ms-python.debugpy-2024.10.0-win32-x64\bundled\libs\debugpy\adapter/../..\debugpy\launcher' '61488' '--' 'C:\Users\Cameron\Documents\advent_of_code\day_1\trebuchet.py'

launch.json { // Use IntelliSense to learn about possible attributes. // Hover to view descriptions of existing attributes. // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 "version": "0.2.0", "configurations": [ { "name": "Python Debugger: Current File", "type": "debugpy", "request": "launch", "program": "${file}", "console": "integratedTerminal" } ] } configuration

XXX

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

XXX

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

XXX

# Behaviour

XXX

Steps to reproduce:

  1. XXX

Diagnostic data

launch.json configuration

XXX

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

XXX

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

XXX

Extension version: 2024.10.0
VS Code version: Code 1.92.0 (b1c0a14de1414fcdaa400695b4db1c0799bc3124, 2024-07-31T23:26:45.634Z)
OS version: Windows_NT x64 10.0.19045
Modes:

  • Python version (& distribution if applicable, e.g. Anaconda): 3.11.9
  • Type of virtual environment used (e.g. conda, venv, virtualenv, etc.): VirtualEnvironment
System Info
Item Value
CPUs AMD Ryzen 5 3600X 6-Core Processor (12 x 3793)
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.93GB (8.66GB free)
Process Argv --crash-reporter-id 341ca450-e247-4d71-9d14-3c2f3a1fb34f
Screen Reader no
VM 0%
A/B Experiments
vsliv368:30146709
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscoreces:30445986
vscod805cf:30301675
binariesv615:30325510
vsaa593cf:30376535
py29gd2263:31024239
c4g48928:30535728
azure-dev_surveyone:30548225
a9j8j154:30646983
962ge761:30959799
pythongtdpath:30769146
welcomedialog:30910333
pythonnoceb:30805159
asynctok:30898717
pythonregdiag2:30936856
pythonmypyd1:30879173
2e7ec940:31000449
pythontbext0:30879054
accentitlementsc:30995553
dsvsc016:30899300
dsvsc017:30899301
dsvsc018:30899302
cppperfnew:31000557
dsvsc020:30976470
pythonait:31006305
dsvsc021:30996838
9c06g630:31013171
pythoncenvpt:31062603
a69g1124:31058053
dvdeprecation:31068756
dwnewjupyter:31046869
2f103344:31071589
impr_priority:31102340
nativerepl2:31104044
refactort:31108082
ccpltc:31103427
pythonrstrctxt:31103193