Bug-Fix Workflow
Systematic root cause analysis and verified fix delivery.
Pipeline
Phase Summary
Hover over any phase name to see what it does in detail.
| # | Phase | Purpose | Key Output |
|---|---|---|---|
| 1 | INTAKE/TRIAGE | Collect problem statement, parse ticket | INTAKE.md |
| 2 | TICKET_GATE | Validate Jira ticket has required info for bug-fix | TICKET_GATE.md |
| 3 | REPRODUCE | Demonstrate broken behavior with actual commands | REPRODUCE.md |
| 4 | RECALL | Search knowledge base for similar past issues | RECALL.md |
| 5 | CODE_TRACE | Find specific code paths involved in the bug | CODE_TRACE.md |
| 6 | BLAST_RADIUS_MAP | Identify all affected code, tests, and components | BLAST_RADIUS_MAP.md |
| 7 | REQUIREMENTS | Define acceptance criteria for ‘fixed’ | REQUIREMENTS.md |
| 8 | TEST_INVENTORY | Document existing tests in the fix area | TEST_INVENTORY.md |
| 9 | DIAGNOSIS | Root cause analysis using all discovery documents | DIAGNOSIS.md |
| 10 | FIX_PLAN | Detailed solution design with specific code changes | FIX_PLAN.md |
| 11 | BASELINE | Run all tests before changes to establish health | BASELINE.md |
| 12 | TEST_GEN | Write new tests for the fix (Category A) | TEST_GEN.md |
| 13 | FIX | Apply fix with red-green cycle | Code changes |
| 14 | VERIFY | Run Category A + B tests to confirm fix | VERIFY.md |
| 15 | BLAST_RADIUS_RUN | Full regression suite (Category C) | BLAST_RADIUS_RUN.md |
| 16 | CLOSE | Summarize, update Jira, create QE sub-task, PR if --pr | CLOSE.md |
| 17 | LEARN | Update knowledge stores with learnings | LEARN.md |
Key Processes
Ticket Gate
TICKET_GATE validates 6 required fields (repro steps, expected/actual behavior, priority, affected area). Blocks with downstream impact analysis if insufficient. Re-fetches ticket on retry. Use /bug-fix PROJ-123 --jira-check to run this check without starting the workflow — it drafts concrete fixes for each gap and can update the ticket for you.
REPRODUCE Verification
Must demonstrate broken behavior with actual commands and output before any analysis begins.
3-Attempt Diagnosis
DIAGNOSIS gets 3 attempts. If root cause is wrong (VERIFY fails), REDIAGNOSE loops back with new evidence. After 3 failures: BLOCKED.
Blast Radius
Mapped before changes (BLAST_RADIUS_MAP) and verified after (BLAST_RADIUS_RUN). Ensures no unintended side effects.
Signal Flow
| Signal | Type | Meaning |
|---|---|---|
| PHASE_COMPLETE | Advance | Phase done, advance to next |
| BLOCKED_NEEDS_HUMAN | Block | Cannot proceed without human input |
| SCOPE_ESCALATION | Block | Scope larger than expected |
| REDIAGNOSE | Loopback | Root cause wrong, loop back to DIAGNOSIS |
| BUG_FIXED | Terminal | Workflow complete |
Loopback: REDIAGNOSE
When VERIFY discovers the fix doesn't resolve the issue, the workflow loops back to DIAGNOSIS with all new evidence.