Review & debugging · 2026-10-10

A bug shows up in about one run out of ten.

You cannot make it happen on demand.

  1. ALabel it flaky and move on to reproducible work
  2. BRun the whole suite a hundred times in CI at a higher temperature until it fails again, then read the logs of whichever run happened to break
  3. CReplay the exact recorded inputs from the failing trace with the sampling pinned, then bisect
  4. DAdd more logging and wait for it to happen in production

Answer: C

Replay the exact recorded inputs from the failing trace with the sampling pinned, then bisect

Why

One in ten is not «unreproducible» - it is «reproduced once, and you kept the recording». A trace holds the exact inputs; replaying them with sampling fixed removes the randomness you were fighting. Repeating the run a hundred times only re-rolls the dice.

More on this topic

More on Way of the Agent

Real situations from building agents - with the answer and why.

Solve a new one every day on the Path