LEVEL 3 · BUILD A GAME / 15 MIN Free NOVEMBER 2026 EDITION · CLAUDE CODE 2.1.318
Bug hunt: when Claude gets confused
Hunt down bugs like a pro: catch the exact error in the browser console, describe precisely how to trigger it, and make sure the fix is real.
Updated 7 November 2026 · Reviewed 7 November 2026
Your mission
Plant a bug in your game on purpose, catch it red-handed in the browser console, give Claude a perfect bug report, and confirm the fix is real, not just “Claude said fixed”.
Why it’s worth it
Every game has bugs. Every app has bugs. Even Claude’s code has bugs, because Claude sometimes gets confused: it misreads what you meant, forgets an edge case, or fixes one thing and nudges another. That’s not a disaster. It’s just Tuesday.
What separates beginners from pros isn’t avoiding bugs, it’s how fast they kill them. And with Claude, the speed depends almost entirely on the clues you hand over. “It’s broken” gives Claude nothing. The exact error message plus how to trigger it gives Claude everything.
The browser console: your bug radar
Browsers have built-in developer tools that show what’s going on under the hood. The most useful part is the Console, where errors appear in red.
- Open it with F12 (or Cmd+Option+I on a Mac), then click the Console tab.
- A red message like
TypeError: Cannot read properties of undefined (reading 'x') game.js:88tells you what went wrong and where (file and line). - Copy the whole red message, with its file and line, and paste it to Claude.
Build it (by breaking it)
Open your neon-dodge folder and start Claude.
1. Plant a bug. Normally you’d find bugs by accident. Today, make one on purpose so you know exactly what “fixed” looks like:
For a debugging exercise: introduce one realistic bug in the game that
makes it crash with a console error when the ship hits a falling block.
Don't tell me what you changed or where.
What you’ll see: Claude makes a sneaky change. Don’t peek at the code!
2. Reproduce it. Refresh the game and play until you crash into a block. Something should go wrong: a freeze, the game over screen not appearing, or a weird state.
3. Catch the evidence. Press F12, open the Console tab, and find the red error. Copy it.
4. Write the bug report. Paste it with the steps to trigger it:
Bug: when the ship hits a falling block, the game freezes instead of showing
game over. Console error:
[paste the red error here]
Find the root cause and fix it. Then explain in two sentences what was wrong.
What you’ll see: Claude reads the error, jumps to the file and line it names, finds the problem and fixes it, then explains what was wrong. The explanation is your quality check: if it matches the error and makes sense, the fix is probably real.
5. Prove it’s fixed. Refresh and crash into a block again, the exact same way. The game over screen should appear and the console should show no new red errors.
GG. You just debugged like a professional: reproduce, collect evidence, report precisely, verify. That loop works on every bug you’ll ever meet.
The perfect bug report
Every great bug report has three parts:
| Part | Example |
|---|---|
| How to trigger it | “Catch a shield, then crash within one second” |
| What happens vs. what should happen | “The game freezes; it should use up the shield and keep going” |
| The evidence | The exact console error, or a screenshot (lesson 2.2) |
Add “find the root cause” to your request. Without it, Claude might just patch the symptom, like hiding the error message, instead of fixing why it happened.
When Claude gets confused
- The fix creates a new bug. It happens. Claude sometimes changes more than it needs to. Rewind to before the fix (lesson 1.3) and ask again, adding: “Change as little as possible.”
- Claude keeps “fixing” but it’s still broken. After two attempts, stop and give it more evidence: a fresh console error, the exact steps, a screenshot. Or ask it to explain how the broken part is supposed to work first; often that reveals the confusion.
- No red error at all, but it still behaves wrong. Not every bug throws an error. Describe the behaviour precisely: “The score goes up by 2 every second instead of 1.”
Did it work?
- You opened the browser console and found a red error
- Your bug report had the trigger, what happened, and the exact error
- Claude explained the root cause in a way that matched the error
- You re-tested the exact same way and the bug was gone
Checkpoint
3 QUESTIONS · CLEAR IT WITH 80%Tip: select the text that's wrong before clicking, and it's quoted in your report.