Your agent reads the error, changes a few lines, and reports the bug fixed. The app still runs, so it is tempting to believe it and move on. But "fixed" is a claim, and a claim is not proof: you never watched the bug actually die. This chapter gets you to prove a fix is real before you trust it.
7.5.1Reproduce before you trust the fix
You cannot confirm a fix you were never able to make fail. Before you trust anything, reproduce the bug yourself: run the exact steps, or feed the exact input, that triggered it, and watch it break. That gives you a repro, the precise steps that force the bug to happen, and it is the one case that proves the fix later.
If the agent jumped straight to a fix without a repro, it was guessing at the cause. Make it show you the bug first, then the fix.
Rule of thumb: you have not fixed a bug until you have watched it fail, then watched the same steps succeed.
7.5.2A real fix, not a hidden symptom
A bug is a symptom of a deeper cause. The fast, wrong move is to silence it: swallow the error, return a safe-looking default, or special-case the one input that broke. The app stops complaining, and the real defect stays in, waiting for the next input.
A root cause fix changes why the bug happened, so the same kind of input can never trigger it again. The difference shows in the code.
7.5.3Test the exact case that failed
Now re-run the exact repro from the first step, unchanged. Not something similar, the same steps that failed before. If it now behaves correctly, and for the reason the fix claims, the bug is dead.
If you quietly changed the input to make it pass, you tested a different bug and left the original one alive.
7.5.4Check nothing else broke
A fix edits code that other features rely on, so it can break something that was working a minute ago. That is a regression: new damage caused by the change itself, not by the original bug. The fix is not done until you have looked for it.
Re-run the things nearest the change: the same feature, the inputs just on either side of the one that broke, the screen it lives on. Doing this by hand every time does not scale, which is why later, when you harden the app, your agent builds automated tests that re-check everything on each change. For one fix, checking the neighbors yourself is enough.
Run all four as one command, and make the agent do the proving, not the promising:
Do this now: take the last bug your agent fixed, reproduce it from before the change if you still can, then paste the prompt with that bug and fix so the agent proves it root-cause dead, not just quiet.