Super Debugger
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Super Debugger debug script.py and show me the variables at line 5"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
🐛 Super Debugger
Servidor MCP para depurar código Python con IA — breakpoints, inspección de variables y ejecución paso a paso en tiempo real.
🤔 ¿Qué es Super Debugger?
Super Debugger es un servidor MCP (Model Context Protocol) que expone herramientas de depuración de Python a cualquier agente de IA compatible (Claude Desktop, Cursor, Cline, Continue, etc.).
En vez de que un LLM adivine la causa de un bug, Super Debugger le permite:
Ejecutar el script y ver el traceback real
Detenerse en breakpoints específicos
Inspeccionar el valor de cada variable en vivo
Avanzar la ejecución paso a paso
Modificar el código y verificar el fix
Todo sin dependencias pesadas: no usa debugpy, ni DAP, ni pdb, ni PTYs. Solo sys.settrace de Python estándar.
Related MCP server: agentic-debugger
✨ Características
Herramienta MCP | Descripción |
| Verifica que el servidor está vivo y responde |
| Lee archivos con números de línea (formato |
| Sobrescribe archivos con backup automático |
| Restaura la versión original si un fix empeora las cosas |
| Ejecuta un script y devuelve exit code + stdout + stderr |
| Lanza el script bajo el debugger con breakpoints |
| Avanza al siguiente breakpoint |
| Inspecciona variables del frame actual sin avanzar |
| Termina la sesión de debug |
Valor único: inspección de variables en vivo sin re-ejecutar ni adivinar.
📦 Instalación
Requisitos
Python 3.12 o superior
uv(recomendado) opip
Pasos
# 1. Clonar el repositorio
git clone https://github.com/ahernandezvega907-crypto/super-debugger.git
cd super-debugger
# 2. Crear el entorno virtual
uv venv --python 3.12
# 3. Activar el entorno
# En Windows:
.venv\Scripts\activate
# En macOS/Linux:
source .venv/bin/activate
# 4. Instalar dependencias (desde pyproject.toml)
uv sync
# 5. Verificar que el servidor carga
python -c "from server import mcp; print('OK')"🚀 Uso
Opción 1: Claude Desktop
Edita claude_desktop_config.json (ubicación por sistema operativo):
Sistema | Ruta |
Windows |
|
macOS |
|
Linux |
|
Agrega este bloque:
{
"mcpServers": {
"super-debugger": {
"command": "/ruta/absoluta/a/super-debugger/.venv/Scripts/python.exe",
"args": ["/ruta/absoluta/a/super-debugger/server.py"]
}
}
}⚠️ Reemplaza la ruta con la ubicación real donde clonaste el repo:
Windows:
C:\\Users\\TuUsuario\\super-debugger\\.venv\\Scripts\\python.exeyC:\\Users\\TuUsuario\\super-debugger\\server.pymacOS/Linux:
/Users/TuUsuario/super-debugger/.venv/bin/pythony/Users/TuUsuario/super-debugger/server.py
Importante: apunta al python del .venv (no al global) para que el servidor encuentre fastmcp.
Reinicia Claude Desktop. Verás el ícono 🔌 en el chat.
Opción 2: Cursor
Edita ~/.cursor/mcp.json (o %USERPROFILE%\.cursor\mcp.json en Windows):
{
"mcpServers": {
"super-debugger": {
"command": "/ruta/absoluta/a/super-debugger/.venv/Scripts/python.exe",
"args": ["/ruta/absoluta/a/super-debugger/server.py"]
}
}
}⚠️ Reemplaza la ruta con la ubicación real donde clonaste el repo (mismas rutas que en Claude Desktop).
Reinicia Cursor y verás el servidor disponible en el chat.
Opción 3: Cline (VS Code)
Instala la extensión Cline desde el Marketplace.
Abre el panel de Cline → MCP Servers → Installed → Configure MCP Servers.
Agrega este bloque en
cline_mcp_settings.json:
{
"mcpServers": {
"super-debugger": {
"command": "C:\\Users\\TuUsuario\\super-debugger\\.venv\\Scripts\\python.exe",
"args": ["C:\\Users\\TuUsuario\\super-debugger\\server.py"],
"disabled": false,
"autoApprove": []
}
}
}Opción 4: Continue
Instala la extensión Continue desde el Marketplace.
Abre
~/.continue/config.yaml(o%USERPROFILE%\.continue\config.yamlen Windows).Agrega este bloque al final del archivo:
mcpServers:
- name: super-debugger
command: "C:\\Users\\TuUsuario\\super-debugger\\.venv\\Scripts\\python.exe"
args:
- "C:\\Users\\TuUsuario\\super-debugger\\server.py"
connectionTimeout: 120000Nota: el connectionTimeout: 120000 es obligatorio — FastMCP tarda más que el timeout por defecto en arrancar.
Opción 5: MCP Inspector (para probar sin IDE)
npx -y @modelcontextprotocol/inspector python server.pyAbre http://localhost:5173 en el navegador.
✅ Clientes validados
Ciclo completo de depuración (run → continue → inspeccionar variables → stop) probado end-to-end con:
Cliente | Estado | Notas |
MCP Inspector (oficial Anthropic) | ✅ Probado | Referencia protocol-level |
Claude Desktop | ✅ Probado | Funciona out-of-the-box |
VS Code + GitHub Copilot Chat | ✅ Probado |
|
Cline | ✅ Probado | Requiere prompts explícitos con modelos gratuitos |
Continue | ✅ Probado | Requiere |
Cursor | ⏳ No probado | Compatible con MCP, pendiente de verificar |
Ver VALIDATION.md para los detalles técnicos, versiones de modelos y notas específicas de cada cliente.
Nota sobre modelos gratuitos: los modelos con soporte limitado de tool calling (ej. Gemini Flash Lite, Pixel Canary) requieren prompts explícitos del tipo:
"Usá EXCLUSIVAMENTE la herramienta MCP
debug_rundel servidorsuper-debugger, sin ejecutar comandos de terminal."
Con esa instrucción, el tool calling funciona correctamente en todos los clientes probados.
🎬 Ejemplo de uso
Código con bug (test_target.py):
def promedio_positivos(numeros):
suma = 0
cantidad = 0
for i in range(len(numeros) + 1): # ← bug: +1 de más
if numeros[i] > 0:
suma += numeros[i]
cantidad += 1
return suma / cantidadLo que hace el agente:
run_script→ detectaIndexError: list index out of rangeread_file→ lee el código con números de líneadebug_runcon breakpoint en línea 5 → se detiene y muestranumeros=[4,-2,7,0,9], i=0debug_continue→ avanza y ve cómoillega hasta5(fuera de rango)write_file→ corrige:range(len(numeros))sin el+1run_script→ verifica:OK (exit 0)con el resultado correcto
Sin adivinar. Sin re-ejecuciones infinitas. Solo inspección en vivo.
🏗️ Arquitectura
Cliente MCP (Claude/Cursor/Cline/Continue)
│ stdio (JSON-RPC)
▼
┌─────────────────────────┐
│ server.py (FastMCP) │
│ 9 herramientas │
└───────────┬─────────────┘
│ subprocess.PIPE
▼
┌─────────────────────────┐
│ debug_wrapper.py │
│ sys.settrace │
│ JSON por stdout │
└─────────────────────────┘Decisiones de diseño:
Sin debugpy: la API DAP requiere un handshake de autenticación complejo que hace frágil la integración.
Sin pdb: requiere TTY real, falla en subprocess.
Sin PTY: los bugs de compatibilidad en Windows lo hacen poco fiable.
sys.settrace: es la API oficial de Python, funciona igual en todos los sistemas.
🧪 Tests
# Test del backend de debug (offline, sin MCP)
python test_tools_offline.py
# Test del cliente debug
python test_debug.py🛠️ Desarrollo
Estructura del proyecto
super-debugger/
├── server.py # Servidor MCP (herramientas expuestas)
├── debug_client.py # Cliente del wrapper
├── debug_wrapper.py # Motor de depuración (sys.settrace)
├── agent.py # (opcional) Agente autónomo con LangGraph
│ # requiere ANTHROPIC_API_KEY (no incluido en el MVP)
├── test_*.py # Tests
├── VALIDATION.md # Evidencia de validación multi-cliente
├── pyproject.toml # Dependencias
└── README.md # Este archivoDependencias
El proyecto usa solo 3 dependencias runtime:
fastmcp— framework del servidor MCPlanggraph— orquestación del agente autónomo (agent.py)langchain-anthropic— cliente de Claude para el agente
Agregar nuevas herramientas
Define la función en
server.pycon el decorador@mcp.tool().Documenta el parámetro
Args:en el docstring.Reinicia el cliente MCP para recargar.
🗺️ Roadmap
MVP: 9 herramientas core
Compatibilidad con MCP Inspector
Validación end-to-end con 5 clientes (MCP Inspector, Claude Desktop, Copilot, Cline, Continue)
Validación con Cursor
Soporte para breakpoints condicionales
Soporte para debugging multi-hilo
Publicación en VS Code Marketplace
Agente autónomo con modelo local (Ollama)
🤝 Contribuir
Pull requests son bienvenidas. Para cambios importantes, abrí un issue primero para discutir qué te gustaría cambiar.
📄 Licencia
MIT — usalo libremente en proyectos personales y comerciales.
🙏 Agradecimientos
FastMCP por el framework del servidor
Model Context Protocol por el estándar
Comunidad de Python por
sys.settrace
Hecho con 🐍 y ☕ por Armando Hernández
Available Tools
9 toolsdebug_continueDebug ContinueB
Continua la ejecucion hasta el siguiente breakpoint o el fin del programa. Si el programa termina o falla, cierra la sesion automaticamente.
Inputs: file_path (required). Returns: result
debug_get_variablesDebug Get VariablesB
Devuelve las variables locales del ultimo breakpoint alcanzado (no reanuda nada).
Inputs: file_path (required). Returns: result
debug_runDebug RunB
Lanza el script bajo el tracer con los breakpoints dados y devuelve el primer STOP. Solo puede haber una sesion activa a la vez.
Inputs: file_path (required), breakpoints (required). Returns: result
debug_stopDebug StopC
Termina la sesion de depuracion.
Inputs: file_path (required). Returns: result
pingPingA
Verifica que el servidor responde.
Inputs: no named parameters. Returns: result
read_fileRead FileB
Lee y devuelve el contenido completo de un archivo de texto, con numeros de linea al principio de cada linea (formato 'N: codigo') para poder referenciar lineas exactas al pedir breakpoints o escribir el fix.
Inputs: path (required). Returns: result
revert_fileRevert FileA
Restaura un archivo a como estaba antes del primer write_file de esta sesion. Usar si un intento de fix empeoro las cosas.
Inputs: path (required). Returns: result
run_scriptRun ScriptA
Corre un script Python normal (sin debugger) y devuelve su codigo de salida, stdout y stderr. Usar para comprobar si el script falla y, despues de aplicar un fix, para verificar si ya quedo corregido.
Inputs: path (required), timeout. Returns: result
write_fileWrite FileB
Sobreescribe un archivo con contenido nuevo completo (no un diff, el archivo entero). Guarda automaticamente el contenido original en memoria la primera vez que se toca ese archivo, para poder revertir.
Inputs: path (required), content (required). Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
Each tool has a distinct role: file operations (read/write/revert), plain execution (run_script), and session-based tracing (debug_run/continue/get_variables/stop). The only mild overlap is run_script vs debug_run, but descriptions explicitly contrast them ('sin debugger' vs 'bajo el tracer'), so an agent can pick correctly. ping is a trivial outlier but harmless.
Nearly all tools use snake_case verb_noun (read_file, write_file, revert_file, run_script) and the debug session tools are consistently grouped under the debug_ prefix. The only deviations are the bare verb 'ping' and the longer 'debug_get_variables', which are still readable and conventional.
Nine tools is well-scoped for a debug-and-fix workflow, with each tool earning its place across file editing, execution, and stepping. No redundant or filler tools beyond the minor ping health check.
The core loop (read with line numbers, edit, revert, run, breakpoint trace, inspect locals) is covered, but inspection is limited to locals at the last breakpoint with no stack trace, no globals, and no expression evaluation. Stepping granularity is also missing—only continue—so an agent cannot step over/into without predefining a breakpoint.
Maintenance
Related MCP Connectors
Agent Replay Debugger MCP — record every agent step + deterministic replay. Step-debugger for
MCP server for Sentry - error monitoring, issue tracking, and debugging for AI assistants
MCP server for agentverse documentation, generated by doc2mcp.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI assistants to perform interactive Python debugging with breakpoints, step execution, and variable inspection using the Debug Adapter Protocol (DAP) through an MCP server interface.81MIT
- AlicenseAqualityDmaintenanceAn MCP (Model Context Protocol) server that enables interactive debugging with code instrumentation for AI coding assistants. Inspired by Cursor's debug mode.75 npm1MIT
- FlicenseNot gradedqualityAmaintenanceAn MCP server and VS Code extension that enables AI clients to interactively debug code using breakpoints, execution control, and state inspection. It is language-agnostic and works with any debugger that supports VS Code's launch.json configurations.-
- AlicenseNot gradedqualityDmaintenanceMCP server for AI-assisted Python debugging using debugpy and Debug Adapter Protocol, enabling AI agents to run tests, set breakpoints, and inspect variables via natural language.8MIT