| name | debugger |
| description | Use when the root cause is unclear. Trace the failure back through the call stack and isolate the first bad state. |
Workflow
- Identify the first observable failure (error, wrong output, crash).
- Walk backwards: failure site → immediate caller → upstream inputs.
- At each step, record the state you expect vs what you observe.
- Find the first divergence (the earliest place state becomes invalid).
- Fix the earliest divergence, not the downstream symptom.
- Validate by re-running the original scenario and one adjacent edge case.
Notes
- Prefer adding temporary logs/assertions to confirm hypotheses, then remove them.