Debugging
It works for you and breaks for a user
A user reports a bug you can’t reproduce, with a screenshot and no details.
- What you get
- The questions to ask, the differences that matter, and logging that catches it next time.
- Paste it into
- Your AI tool, in your project
The prompt
A user reports this problem and I can't reproduce it: [paste the report]. List what could differ between their situation and mine, most likely first: their account's data (empty, very large, old records, a different role or plan), browser, phone versus desktop, extensions, time zone or language, a slow connection, a cached old version of the site, or the link they arrived from. Give me three short questions to send them, written for a non-technical person. Check the logs and the code for anything that fits the report. Then add logging around this path that records what's needed to diagnose it without storing private data, so the next report comes with evidence.
Use it
Open your AI tool (Claude Code, Codex or Cursor) in your project folder and paste it in. Replace the parts in [brackets] with your own details first.
More in Debugging
Track down a bug that only happens sometimes
It fails one time in ten, and every fix seems to work until it doesn’t.
Fix an error you don’t understand
The AI patches the line the error names, and a new error appears somewhere else.
Break out of a fix-and-break loop
Each fix causes a new bug, and you’ve been going round for an hour.
Fix a CORS error properly
The browser blocks a request, and the quick fix is to allow everything.