Fix a Bug
Find the root cause before anyone touches the code.
Use Cursor
Its agent reads the project, edits the code and runs the tests.
Open CursorSave it as error.log. Ask Cursor's agent to rerun the failing command and save the whole output, stack trace included, to error.log in your project.
Give your agent the Systematic Debugging skill
Makes the agent find the root cause before it proposes a fix.
The skill is in this folder, at skill/systematic-debugging. Copy it into your agent's skills folder, or install it from its maker:
/plugin install superpowers@claude-plugins-officialSave it as debug-notes.md. Paste the trace, code and steps from debug-notes.md into {{Error message and stack trace}}, {{Relevant code}} and {{What you were doing}}.
Run the Debugging for Errors and Stack Traces prompt
The root cause, a quick way to confirm it and the fix, from your stack trace.
Any capable chat assistant can debug a pasted stack trace; a coding agent that can run your code and read the whole project helps when the cause sits outside the files you paste.