Multiprocessing child processes stall during VSCode debugpy breakpoints
@heejaechang is already working on this.
Since May 14, 2025.
Assessment
This issue has not been assessed yet.
Description
Environment data
- debugpy version: 1.8.13
- OS and version: Windows 11
- Python version: 3.12+ (python standalone by uv)
- Using VS Code or Visual Studio: VS Code 1.100.1 (Universal) on macOS tunneled to Windows with same version VS Code
Actual behavior
I have a running child process which draws some rectangles on screen. If I hit a breakpoint in my main process now I can't manually trigger rectangles drawing from the REPL. This isn't working with debugpy and python 3.12+ - it is working though with Python 3.11.12. Outside of VS Code with f.e. pdb.set_trace() it's working in all versions of Python I've tested.
Expected behavior
The child process keeps working and I can manually trigger things.
Steps to reproduce:
minimal example, tested with Python 3.13.3 on Windows and issue persists.
import multiprocessing
import time
def child_process(q):
while True:
msg = q.get()
if msg == "STOP":
print("Child received STOP command.")
break
print(f"Child received: {msg}")
time.sleep(0.5)
if __name__ == "__main__":
multiprocessing.freeze_support()
queue = multiprocessing.Queue()
child = multiprocessing.Process(target=child_process, args=(queue,))
child.start()
for i in range(3):
queue.put(f"Message {i}")
time.sleep(1)
# Set a breakpoint on the next line in VSCode
queue.put("Message at breakpoint") # BREAKPOINT HERE
# execute in REPL at breakpoint queue.put(f"Hello from REPL")
# Try to continue communication after breakpoint
queue.put("Final message")
queue.put("STOP")
child.join()
print("Parent process complete.")
no launch.json in use, I've just hit the "Debug Python File" icon in VS Code.
- Dominant language
- Python
- Stars
- 2.5k
- Forks
- 202
- Avg merge
- 5d 1h
- Merged PRs (30d)
- 1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/debugpy
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
-
Difficulty 3/5 1-2 days Newbie friendliness 68/100
All issues in microsoft/debugpy
Similar issues
-
essnmx good first issue
Difficulty 1/5 Under an hour Newbie friendliness 95/100
-
[Feature] 奇物选择添加优先级 Open
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
syfoud/Simulated_Scepter#174 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Giskard-AI/giskard-oss#2840 · 1 comment ·
-
A claim comment carrying the issue number is silently declined while the workflow reports success Openarea: repo bug perceived difficulty: 2
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
yeti-platform/yeti#1380 ·