Asked about Debugging systematically

A bug reproduces about one run in twenty. How do you work on it?

An answer that works

Measure the rate before changing anything, because a clean run proves almost nothing: at one in twenty, three consecutive passes happen about 85 per cent of the time, and you need around 59 runs to be 95 per cent sure of seeing it once. Then remove one source of variance at a time — fix the seed, temperature to zero, a single worker, a frozen clock — and see which one it hangs from. Separately, capture the full context of every failure as it happens, because you cannot go back and collect it.

What gets marked up

Strong answers give a rate rather than a story, and say what they would capture. Re-running until it passes is the answer being tested for.

Reading an answer is not being able to give one. The section that teaches this is Debugging systematically, 5 hours of Debugging.

Learn this properly