en un clic
fix-issue
Bug fix workflow with 3-hypothesis debugging protocol
Installer avec Codex ou Claude Copiez ce prompt, collez-le dans Codex, Claude ou un autre assistant, puis laissez-le vérifier la page du skill et l'installer pour vous.
Menu
Bug fix workflow with 3-hypothesis debugging protocol
Installer avec Codex ou Claude Copiez ce prompt, collez-le dans Codex, Claude ou un autre assistant, puis laissez-le vérifier la page du skill et l'installer pour vous.
Finish feature with tests, commit, and session closure
Start feature with branch and session tracking
Interactive wizard to configure the project
System-wide code audit with 8 modules
Environment-aware deployment with pre/post checks
Methodical codebase exploration and understanding
Basé sur la classification professionnelle SOC
| name | fix-issue |
| description | Bug fix workflow with 3-hypothesis debugging protocol |
| argument-hint | ["issue-number|description"] |
| disable-model-invocation | true |
| allowed-tools | Bash(git:*), Bash(*test*), Read, Write, Edit, Glob, Grep |
Read .claude/project.config.json to get project configuration.
Variables to use:
{testCmd} = config.commands.test (default: npm test){mainBranch} = config.git.mainBranch (default: main){fixPrefix} = config.git.branchPrefixes.fix (default: fix/){coAuthoredBy} = config.git.coAuthoredBy (default: false)Read context/FIXES.md for existing bug reports and fix history.
Determine the issue source based on $ARGUMENTS:
If numeric (e.g., 42):
gh issue view $ARGUMENTS --json title,body,labels,comments
If text description (e.g., login-timeout):
Read context/FIXES.md and search for existing reports matching the issue:
If match found in Pending:
If match found in Resolved:
If no match found:
Search for code related to the issue:
src/Report findings:
### Affected Code
| File | Line | Relevance |
|------|------|-----------|
| `{file}` | {line} | {why this file is relevant} |
MANDATORY: Before writing any fix, formulate and validate hypotheses.
Based on the issue context and code analysis, formulate at least 3 hypotheses about the root cause:
### Hypotheses
| # | Hypothesis | Confidence | Validation Method |
|---|-----------|------------|-------------------|
| 1 | {description} | HIGH/MED/LOW | {how to verify} |
| 2 | {description} | HIGH/MED/LOW | {how to verify} |
| 3 | {description} | HIGH/MED/LOW | {how to verify} |
For each hypothesis, gather evidence:
### Validation Results
| # | Hypothesis | Evidence | Verdict |
|---|-----------|----------|---------|
| 1 | {description} | {what was found} | CONFIRMED / REJECTED / INCONCLUSIVE |
| 2 | {description} | {what was found} | CONFIRMED / REJECTED / INCONCLUSIVE |
| 3 | {description} | {what was found} | CONFIRMED / REJECTED / INCONCLUSIVE |
Fix the confirmed root cause:
Run tests to verify the fix:
{testCmd}
Read and update context/FIXES.md:
If item was in Pending/In Progress:
### FIX-{NNN}: {title}
- **Severity**: {severity}
- **Root cause**: {confirmed hypothesis}
- **Fix**: {what was changed}
- **Files**: {list of modified files}
- **Date resolved**: {date}
- **Session**: {session-ID if applicable}
If item was not registered:
Create commit with fix prefix:
If from GitHub issue (numeric $ARGUMENTS):
git add {modified files}
git commit -m "fix(scope): description (closes #$ARGUMENTS)
- Root cause: {confirmed hypothesis}
- Fix: {what was changed}
"
If from description:
git add {modified files}
git commit -m "fix(scope): description
- Root cause: {confirmed hypothesis}
- Fix: {what was changed}
"
Co-Authored-By: Check config.git.coAuthoredBy:
true: add Co-Authored-By: Claude <noreply@anthropic.com>false (default): do NOT include AI attribution| Problem | Recovery |
|---|---|
| GitHub CLI not installed | Skip gh issue view, ask user for issue details manually |
| Issue not found on GitHub | Treat as text description, proceed with manual context |
| All hypotheses rejected | Formulate 3 new hypotheses with broader scope |
| Tests fail after fix | Revert fix, re-examine root cause, try alternative approach |
| FIXES.md not found | Create it with standard template from context/FIXES.md |
| Fix introduces new failures | Check if failure is pre-existing; if new, investigate before committing |
| Complexity | Approach |
|---|---|
| Quick fix (1-2 files, clear cause) | Complete this flow directly |
| Complex fix (multi-file, unclear) | Use /start fix-{name} for full session tracking |
| Batch fix (multiple small related) | Group fixes, single commit, log all in FIXES.md |