Enforces strict reproduce-first, root-cause-first, failing-test-first workflow for debugging bugs, test failures, or unexpected behavior.
How this skill is triggered — by the user, by Claude, or both
Slash command
/engineering-discipline:systematic-debuggingThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
A strict debugging workflow. Use when dealing with bugs, test failures, or unexpected behavior.
A strict debugging workflow. Use when dealing with bugs, test failures, or unexpected behavior.
Three core purposes:
These rules have no exceptions.
Violating this process is considered a debugging failure.
Use this skill in the following situations:
The following excuses are not accepted:
When using this skill, the following items must be locked internally:
If any of these seven items are missing, the work is not done.
Follow the steps below in order.
First, condense the problem.
Output format:
Problem: <expected> but got <actual> under <condition>
Do not mix symptoms with speculation.
Good: Product detail API returns 500 when brand is null.
Bad: Serializer is broken because brand mapping seems wrong.
You must be able to see the failure again before fixing it.
Priority:
Rules:
What to do when reproduction is not possible:
Collect only observable facts.
Always check:
For multi-component problems, check at each boundary.
Examples:
At each boundary, check:
Do not fix until you have pinpointed the problem location.
Formulate exactly one cause candidate.
Format:
Hypothesis: <root cause> because <evidence>
Qualities of a good hypothesis:
Examples of bad hypotheses:
Trace the cause back to the source. If the error appears deep in the stack, trace the origin of the input, not the symptom.
Lock the failure before fixing.
Priority:
Rules:
If an automated test is feasible, use the test-driven-development skill alongside this one.
The fix addresses only one hypothesis.
Allowed:
Forbidden:
If the fix fails, immediately return to Phase 1 or Phase 3. The previous hypothesis was wrong.
All of the following must be satisfied before closing:
For intermittent bugs, a single pass is not enough. Verification under repeated runs or varying conditions is required.
Stop and reframe in the following situations.
If reproduction fails after multiple attempts:
Changing code without reproduction is forbidden.
If three consecutive fixes miss the mark, conclude:
From this point, a "fourth patch" is not the answer — a structural discussion is needed.
If you cannot create a failing test or equivalent reproduction mechanism, do not declare completion. At minimum, leave behind the reproduction command and observed results.
If any of the following thoughts arise, stop immediately and return to an earlier phase.
Use this checklist for self-verification during execution.
The completion criterion for this skill is not "the code changed."
Completion criteria:
Without these four, debugging is not finished.
npx claudepluginhub tmdgusya/engineering-discipline --plugin engineering-disciplineEnforces systematic root cause analysis before fixes for bugs, test failures, unexpected behavior, performance issues, and build failures.
Guides bug fixing through four phases: reproduce, understand, hypothesize, fix and verify. Use before proposing fixes for any bug or test failure.
Enforces systematic root cause investigation for bugs, test failures, and unexpected behavior through four phases: investigation, pattern analysis, hypothesis testing, and implementation.