microsoft / microsoft/vscode-python-debugger

Program doesn't stop on "Python Debugger Console" kill

Open
#641 12 comments 0 reactions 1 assignee View on GitHub

@eleanorjboyd is already working on this.

Since Mar 4, 2025.

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

Description

Type: Bug

Behaviour

On linux (Ubuntu 24.04 exactly), active python process doesn't stop on closing "Python Debugger Console" and debugger UI dissappears. On Windows 10 acts as expected.

Steps to reproduce:

  1. Run next script
import time
i = 0
while True:
    with open("counter.txt", "w") as f:
        f.write(str(i))
    time.sleep(1)
    i += 1
  1. Close "Python Debugger Console" through "Kill (Delete)" button
  2. Debugger UI dissappears, but created file "counter.txt" is still being updated

Diagnostic data

launch.json configuration

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

2025-02-28 20:08:10.017 [info] Send text to terminal: 
2025-02-28 20:08:10.218 [info] Send text to terminal:  cd _ ; /usr/bin/env _/.venv/bin/python3 /root/.vscode-server/extensions/ms-python.debugpy-2025.0.1-linux-x64/bundled/libs/debugpy/adapter/../../debugpy/launcher 46307 -- _/main.py 

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

2025-02-28 20:08:09.464 [info] Resolving launch configuration with substituted variables
2025-02-28 20:08:09.628 [info] DAP Server launched with command: _/.venv/bin/python3 /root/.vscode-server/extensions/ms-python.debugpy-2025.0.1-linux-x64/bundled/libs/debugpy/adapter
2025-02-28 20:08:09.937 [info] Received 'debugpySockets' event from debugpy.
2025-02-28 20:08:10.012 [info] Received 'debugpySockets' event from debugpy.
2025-02-28 20:08:10.013 [info] Received 'debugpySockets' event from debugpy.
2025-02-28 20:08:10.612 [info] Received 'debugpySockets' event from debugpy.
2025-02-28 20:08:16.956 [info] Received 'debugpySockets' event from debugpy.
2025-02-28 20:08:17.043 [info] Received 'debugpySockets' event from debugpy.

Extension version: 2025.0.1
VS Code version: Code 1.97.2 (e54c774e0add60467559eb0d1e229c6452cf8447, 2025-02-12T23:20:35.343Z)
OS version: Windows_NT x64 10.0.19045
Modes:
Remote OS version: Linux x64 6.8.0-51-generic

  • Python version (& distribution if applicable, e.g. Anaconda): 3.12.3
  • Type of virtual environment used (e.g. conda, venv, virtualenv, etc.): VirtualEnvironment
System Info
Item Value
CPUs 11th Gen Intel(R) Core(TM) i5-11260H @ 2.60GHz (12 x 2611)
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.71GB (7.84GB free)
Process Argv --folder-uri vscode-remote://ssh-remote%2Bpureservers/home/projects --crash-reporter-id 3eae2273-f521-4059-a6b4-e3bdc79661a8
Screen Reader no
VM 0%
Item Value
Remote SSH: pureservers
OS Linux x64 6.8.0-51-generic
CPUs AMD Ryzen 9 3900 12-Core Processor (1 x 0)
Memory (System) 1.92GB (0.56GB free)
VM 0%

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.