debug_python_repro
Launch a reproducible Python bug under debugpy, set breakpoints, run to the first stop, and return the stack plus top-frame locals for inspection.
Instructions
Use this first for a reproducible Python bug. Launch a Python script under debugpy, set breakpoints, continue to the first stop, and return stack plus top-frame locals.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"program": "<program>"
},
"name": "debug_python_repro"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | Working directory for the target program. | |
| env | No | Environment variables to add to the target process. | |
| args | No | ||
| python | No | Python executable to use for debugpy and the target. | |
| program | Yes | Path to the Python script that reproduces the bug. | |
| timeout | No | ||
| breakpoints | No | Breakpoints to set before the script starts running. | |
| keep_session | No | Keep the session open after the first stop so the agent can step or inspect more. | |
| locals_limit | No | ||
| stop_on_entry | No |