python-debugpy

Debug Python execution with pdb and debugpy over DAP.

Updated Apr 9, 2026
One-click install
npx skills add https://github.com/MarbleSodas/Mavis --skill python-debugpy-marblesodas
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: python-debugpy
Source: https://github.com/MarbleSodas/Mavis/tree/main/skills/software-development/python-debugpy
Command: npx skills add https://github.com/MarbleSodas/Mavis --skill python-debugpy-marblesodas

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It helps you diagnose confusing Python failures by letting you inspect variables, step through code, and debug long-running processes that you cannot easily restart.

Core Features & Use Cases

  • Break at the exact line with breakpoint() or python -m pdb for interactive local inspection when a traceback alone is not enough.
  • Remote/Headless debugging with debugpy (DAP) to attach to already-running processes and debug Hermes-style gateway, daemon, or child workers.
  • Post-mortem inspection to open a debugger session at the crash site and examine locals in the failing frame.

Use case: Your Hermes gateway misbehaves and you only have symptoms; attach a DAP client to the live process, set a breakpoint in the handler code, and step through the failing logic.

Quick Start

Run your failing service with debugpy listening and wait for a client attachment so you can set breakpoints and inspect locals in the moment.

Frequently Asked Questions about python-debugpy

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug a running Python service without restarting it?

Remote debugging a running Python service uses debugpy to listen for a DAP client attachment. You attach an IDE to the live process to set breakpoints and inspect variables in the moment.

Can I inspect variables at the exact line where a Python traceback occurs?

Post-mortem inspection opens a debugger session at the crash site to examine locals in the failing frame. You use breakpoint() or python -m pdb for interactive local inspection when a traceback is not enough.

Does debugpy work with child workers and pytest-xdist subprocesses?

Debugpy can attach to child workers and subprocesses, but pytest-xdist introduces specific caveats. You must apply the correct listen and attach patterns to debug these distributed Python execution contexts.

What is the best way to debug a Hermes gateway that misbehaves with only symptoms?

Remote debugging with debugpy is the best way to diagnose a misbehaving Hermes gateway. You attach a DAP client to the live process, set a breakpoint in the handler code, and step through the failing logic.

Are there limitations when debugging threads and async Python code?

Debugging Python threads and async code has specific limitations. You must account for thread and async constraints when using debugpy and pdb for interactive inspection and step execution.

Do I need an IDE to use debugpy for remote Python debugging?

Remote Python debugging with debugpy requires a DAP-compatible client to attach to the listening process. You run your failing service with debugpy listening and wait for a client attachment to set breakpoints.