MCP server that gives AI agents real debugger access.
Dapug is an MCP server that gives AI agents real debugger access. It connects to language-specific debug adapters (DAP) so an agent can set breakpoints, run programs, inspect variables, step through code, and diagnose bugs -- all through standard MCP tool calls with no human in the loop.
cargo install dapugDownload a prebuilt binary from GitHub Releases. Available platforms:
- x86_64 Linux (musl, static)
- aarch64 Linux (musl, static)
- x86_64 macOS
- aarch64 macOS (Apple Silicon)
Dapug requires a debug adapter for each language you want to debug.
| Language | Adapter | Install |
|---|---|---|
| Python | debugpy | pip install debugpy |
| Go | Delve (dlv) | go install github.com/go-delve/delve/cmd/dlv@latest |
| JavaScript/TypeScript | js-debug | Included with VS Code, or install via vscode-js-debug |
Option 1 -- CLI:
claude mcp add --transport stdio --scope user dapug -- dapugOption 2 -- add to .mcp.json in your project root:
{
"mcpServers": {
"dapug": {
"command": "dapug",
"args": []
}
}
}Add to your config file:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"dapug": {
"command": "dapug",
"args": []
}
}
}Add to .cursor/mcp.json in your project root:
{
"mcpServers": {
"dapug": {
"command": "dapug",
"args": []
}
}
}| Tool | Description |
|---|---|
start_session |
Start a debug session for a program. Returns a session ID. |
set_breakpoint |
Set a breakpoint at a specific line in a source file. |
run |
Start program execution after setting breakpoints. |
wait_for_stop |
Wait for the program to stop at a breakpoint, exception, or exit. Returns stop location and local variables. |
step_over |
Step over one line. |
step_into |
Step into the function call on the current line. |
step_out |
Step out of the current function. |
continue |
Continue execution until next breakpoint or exit. |
inspect |
Evaluate an expression in the current stopped frame. |
get_stack_trace |
Get the current call stack with file, line, and function name. |
end_session |
End a debug session and free all resources. |
list_sessions |
List all active debug sessions. |
end_all_sessions |
End all active debug sessions. |
MIT OR Apache-2.0