main

name: systematic-debugging description: Evidence-driven debugging for bugs, failures, and unexpected behavior. USE WHEN a test fails, software behaves unexpectedly, or a build or integration breaks.

Systematic Debugging

Do not stack speculative fixes. Establish the cause before changing behavior.

  1. Read the complete error and reproduce the failure when possible.
  2. Inspect recent changes, configuration, and inputs at the failing boundary.
  3. Find a comparable working path and list meaningful differences.
  4. State one hypothesis: the suspected root cause and supporting evidence.
  5. Test that hypothesis with the smallest diagnostic or change.
  6. Fix the root cause, not the visible symptom.
  7. Verify the original failure is resolved and run relevant regression checks.

Multi-component failures

Trace data across each boundary: what enters, what exits, and the relevant configuration or environment. Instrument or inspect only enough to identify the first failing boundary.

When uncertain

Gather more evidence or ask for context. After several disproven hypotheses, stop and reassess the design rather than continuing to layer fixes.

Verify

Report the reproduction, root cause, fix, and checks run. Add a regression test when practical; use test-driven-development for its test-first workflow.