Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

The dead thread won't disappear in call stack monitor

Open
#1,572 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
42/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
devtools

Research direction

Start by running the minimal Python reproduction from the issue with gevent and the described VS Code launch.json configuration on Windows. Inspect how the call stack monitor handles the terminated thread and verify that the dead thread disappears immediately without resizing the stack monitor.

Written by the indexing model from the issue text.

Description

bug

Environment data

  • debugpy version: 1.8.1, install from PyPI
  • OS and version: Windows 10.0.19045.4291
  • Python version cPython 3.9.13 downloaded from python.org
  • Using VS Code or Visual Studio: VS code

Actual behavior

here is the minest reproduce code:

import gevent
import gevent.monkey; gevent.monkey.patch_all()
import subprocess
import threading

cmd = 'ver'
info = subprocess.check_output(cmd,
                                stdin=subprocess.DEVNULL,
                                stderr=subprocess.DEVNULL,
                                text=True,
                                shell=True)
print(f'{cmd} => {info}')

https://github.com/microsoft/debugpy/assets/30763045/2fdeeaba-f8f7-4895-a3bd-2ece76c4014d

the dead thread won't disappear immediately util the stack monitor ajust size.

Expected behavior

the dead thread should disappear immediately.

Steps to reproduce:

  1. paster the code to file
  2. take the breakpoint
  3. create a python debug config, add gevent needed env to launce.json, then launch.

W86KA0TY5R$ 20`MHR%CH$9

Dominant language
Python
Stars
2.5k
Forks
202
Avg merge
5d 1h
Merged PRs (30d)
1

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.

More from microsoft/debugpy

All issues in microsoft/debugpy

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.