python-debugpy

Debug Python code interactively via pdb and remote debugpy DAP protocol.

2|Updated May 10, 2026
One-click install
npx skills add https://github.com/freedomw1987/tree_monstor --skill python-debugpy-freedomw1987
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: python-debugpy
Source: https://github.com/freedomw1987/tree_monstor/tree/main/skills/software-development/python-debugpy
Command: npx skills add https://github.com/freedomw1987/tree_monstor --skill python-debugpy-freedomw1987

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill eliminates the frustration of debugging Python code when standard tracebacks don't reveal root causes, covering local scripts, failing tests, long-running processes, and post-crash inspection scenarios.

Core Features & Use Cases

  • Local Interactive Debugging: Use built-in pdb via breakpoint() or python -m pdb for quick, no-setup debugging of local scripts and failing tests.
  • Remote Process Debugging: Attach debugpy to long-running processes like Hermes gateways or daemons to debug issues without restarting them.
  • Post-Mortem Debugging: Inspect local variables and call stacks immediately after unhandled exceptions in production-like code. Use case: If a Hermes gateway subprocess is misbehaving, use this skill to attach a debugger to the running process without disrupting its operation.

Quick Start

Use the python-debugpy skill to debug the failing Python test by launching it under pdb to inspect variable states and call stacks at the point of failure.

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 failing Python test interactively?

Debug a failing Python test by launching it under pdb via breakpoint() or python -m pdb to inspect variable states and call stacks at the point of failure.

Can I attach a debugger to a long-running Python process without restarting it?

Remote debugging via debugpy lets you attach a debugger to long-running Python processes like daemons to inspect issues without restarting them. You connect remotely using the DAP protocol.

What is post-mortem debugging in Python and when do I need it?

Post-mortem debugging in Python allows you to inspect local variables and call stacks immediately after an unhandled exception crashes your process. It is needed when standard tracebacks do not reveal root causes.

Does this remote debugging approach work with the debugpy DAP protocol?

Remote debugging uses the debugpy DAP protocol to attach to Python processes. This enables breakpoint management, call stack traversal, and variable inspection for local scripts and production-like code.

What's the best way to traverse call stacks and inspect variables in Python?

Interactive debugging via pdb REPL provides the best way to traverse call stacks and inspect variables in Python. It supports breakpoint management for local scripts, failing tests, and post-mortem inspection.