Paste the error and the last thing you changed
A stack trace alone gets you a guess. A stack trace plus your last change gets you a diagnosis.
The prompt
This test started failing. Here is the error: [error]. The only change since it last passed: [diff]. What is the most likely cause? Give me one cause and the evidence for it before suggesting any fix.
What Claude gave back
Most likely cause: the new default on line 14 changes the type of `limit` from number to string, so the comparison on line 31 is always false. Evidence: the error says `expected 10, received "10"`, and your diff is the only place `limit` is set.
Asking for the evidence first is the trick. It stopped Claude from jumping to a fix and made the answer easy to check.
Debugging prompts fail when Claude has to work out what changed. You already know. Tell it.
Asking for one cause plus evidence, before any fix, keeps the answer short and checkable.