fix-bug
Skill8 starsChanged 5 months agoMITView on GitHub
Run the Fix Validation pipeline to investigate, fix, and validate a bug. Ensures deterministic pipeline execution with IssueAnalyzer, FixWriter, TestWriter (conditional), TestAudit (conditional), and FixValidator stages.
40 other projects use a version of this.
Adopted by
Most recently taken up by
- Doist/todoist-aitheir own version, first seen Nov 9, 2026
- Doist/todoist-clitheir own version, first seen Nov 8, 2026
- danielvm-git/bigpowerstheir own version, first seen Nov 6, 2026
- tddworks/ClaudeBartheir own version, first seen Nov 3, 2026
- mthines/agent-skillstheir own version, first seen Oct 30, 2026
- aantoniadis/skillstheir own version, first seen Oct 20, 2026
Used with
Projects with it also use improvement, build-feature and 9 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
kiminmonacoSkillimprovement
Guide for making improvements to existing ClaudeBar functionality using TDD. Use this skill when: (1) Enhancing existing features (not adding new ones) (2) Improving UX, performance, or code quality (3) User asks "improve X", "make Y better", or "enhance Z" (4) Small enhancements that don't require full architecture design For NEW features, use implement-feature skill instead.
Also in 4 projects that use this
sirakinbSkillbuild-feature
Autonomous task loop that picks ready tasks, implements them, updates progress.txt, commits, and repeats. Use when asked to 'build feature', 'run the loop', or 'implement these tasks'.
Also in 5 projects that use this
kiminmonacoSkillimplement-feature
Guide for implementing features in ClaudeBar following architecture-first design, TDD, rich domain models, and Swift 6.2 patterns. Use this skill when: (1) Adding new functionality to the app (2) Creating domain models that follow user's mental model (3) Building SwiftUI views that consume domain models directly (4) User asks "how do I implement X" or "add feature Y" (5) Implementing any feature that spans Domain, Infrastructure, and App layers
Also in 7 projects that use this
SentrySkillwrite-tests
Write tests following project conventions. Use when adding new tests or modifying existing ones.
Also in 6 projects that use this
JetBrainsSkillcreate-plan
Research the codebase and create an implementation plan with architecture notes, design document, and track decomposition. Use when starting a new feature or large change.
Also in 4 projects that use this
JasonPaffSkillimplement-plan
Execute implementation plan with structured tracking and validation using subagent architecture
Also in 3 projects that use this
Other versions40 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 40
- remix-run/react-router★ 57ksame name
- ktorio/ktor★ 15ksame name
- JetBrains/Exposed★ 9.3ksame name
- bytebase/dbhub★ 3.8ksame name
- The-OpenROAD-Project/OpenROAD★ 3.3ksame name
- JamieMason/syncpack★ 2.1ksame name
- tddworks/ClaudeBar★ 1.6ksame name
- Harry-kp/vortix★ 757same name
- Doist/todoist-ai★ 563same name
- tddworks/asc-cli★ 393same name
30 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository29 other files it gives its agents.
- anthropic-validatorSkill
- assertion-patternsSkill
- bug-magnet-dataSkill
- bulwark-brainstormSkill
- bulwark-researchSkill
- bulwark-scaffoldSkill
- bulwark-statuslineSkill
- bulwark-verifySkill
- code-reviewSkill
- component-patternsSkill
- continuous-feedbackSkill
- create-skillSkill
- create-subagentSkill
- governance-protocolSkill
- initSkill
- issue-debuggingSkill
- mock-detectionSkill
- pipeline-templatesSkill
- plan-creationSkill
- plan-to-tasksSkill
- product-ideationSkill
- session-handoffSkill
- setup-lspSkill
- spec-drift-checkSkill
- subagent-output-templatingSkill
- subagent-promptingSkill
- test-auditSkill
- test-classificationSkill
- test-fixture-creationSkill
The file
We split this skill into the rules it gives an agent
9 rules. 0 are common, 8 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 40 edited versions we read keep these.
8
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 62
When invoked, follow the Fix Validation pipeline exactly:
- Very specific: line 127
Condition: Check debug report's validation_plan.recommendation.new_tests_needed
- Distinctive: line 130
Write tests that verify the fix
- Distinctive: line 132
Follow T1-T4 rules (no mocking system under test)
- Distinctive: line 138
Condition: Run if any test files were created or modified in Stage 2 (FixWriter) OR Stage 3 (TestWriter).
- Distinctive: line 140
Action: Run mock-detection on new/modified tests to verify T1-T4 compliance
- Distinctive: line 190
No new issues introduced
- Distinctive: line 195
If rejected and iterations < 3:
- Distinctive: line 205
After each stage, report progress to user:
“Common” is measured: kept by at least 6 in 10 of the 40 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Fix Bug Pipeline
This skill triggers the Fix Validation pipeline to systematically investigate, fix, and validate a bug.
When to Use This Skill
Load this skill when the user request matches ANY of these patterns:
| Trigger Pattern | Example User Request |
| Bug fix requests | "Fix this bug", "Something is broken in X" |
| Error investigation | "Users report errors in X", "This feature isn't working" |
| Regression fixes | "This used to work", "Breaking after recent changes" |
| Production issues | "Login fails for new accounts", "API returns 500" |
| Flaky behavior | "Tests pass sometimes", "Intermittent failures" |
DO NOT use this skill for:
| Anti-Pattern | Use Instead |
| Ad-hoc fixes without investigation | Direct fix (skip pipeline) |
| Simple typo corrections | Direct edit |
| Refactoring without reported issues | Code Review pipeline |
| Adding new features | New Feature pipeline |
| Performance optimization | Research & Planning pipeline |
Why This Skill Exists
Without this skill, conversational prompts like "please investigate and fix this bug" may cause Claude to skip pipeline stages and fix directly. This skill ensures deterministic execution of all Fix Validation pipeline stages.
Usage
/fix-bug <path> [description]Arguments:
$1(required): Path to code with the bug$2and beyond (optional): Description of the issue - recommended for better analysis
Examples:
/fix-bug src/auth/login.ts "Users report login fails for new accounts"
/fix-bug tests/fixtures/fix-validator/simple-fix/ "Cannot read property displayName of undefined"
/fix-bug src/api/routes.tsPipeline Stages
When invoked, follow the Fix Validation pipeline exactly:
IssueAnalyzer (bulwark-issue-analyzer) // Sonnet - root cause analysis
|> FixWriter (bulwark-implementer) // Opus - implement fix
|> (if !tests_cover_scenario // Conditional: only if tests don't already exist
then TestWriter |> TestAudit // Opus writes, then audit for T1-T4
else Skip)
|> FixValidator (bulwark-fix-validator) // Sonnet - validate against debug report
|> CodeReviewer (general-purpose) // Sonnet - review fix
|> (if !approved
then IssueAnalyzer // Loop back
else Done)
|> LOOP(max=3) // Max 3 iterationsExecution Instructions
Stage 1: IssueAnalyzer
MUST spawn bulwark-issue-analyzer agent via Task tool:
Task(
subagent_type="bulwark-issue-analyzer",
model="sonnet",
prompt="GOAL: Analyze the bug and produce a debug report..."
)Input: Path from $1, description from $2 onward
Output: Debug report at logs/debug-reports/{issue-id}-{timestamp}.yaml
Do NOT skip this stage. The debug report is required for subsequent stages.
Stage 2: FixWriter
MUST spawn bulwark-implementer agent via Task tool:
Task(
subagent_type="bulwark-implementer",
prompt="GOAL: Fix the identified issue based on the debug report.
CONSTRAINTS: Only fix the identified issue. Write tests for the fix. Max 3 quality gate retries.
CONTEXT:
mode: fix
debug_report_path: logs/debug-reports/{issue-id}-{timestamp}.yaml
root_cause: {from Stage 1}
affected_files: {from Stage 1}
fix_approach: {from Stage 1}
OUTPUT: Implementation report at logs/implementer-{id}-{timestamp}.yaml"
)Input: Debug report from Stage 1
Output: Implementation report at logs/implementer-{id}-{timestamp}.yaml
SA6 Note: The implementer returns pipeline suggestions with MANDATORY language in its summary. Evaluate each suggestion per SA6.
Do NOT implement the fix yourself. The implementer agent handles quality gates and structured output.
Stage 3: TestWriter (Conditional)
Condition: Check debug report's validation_plan.recommendation.new_tests_needed
If tests needed:
- Write tests that verify the fix
- Cover the specific bug scenario
- Follow T1-T4 rules (no mocking system under test)
If tests exist: Skip to Stage 3b or Stage 4
Stage 3b: TestAudit (Conditional)
Condition: Run if any test files were created or modified in Stage 2 (FixWriter) OR Stage 3 (TestWriter). This ensures implementer-written tests receive T1-T4 audit even when TestWriter is skipped.
Action: Run mock-detection on new/modified tests to verify T1-T4 compliance
If T1 violation: Return to TestWriter (or FixWriter if TestWriter was skipped), request rewrite
If T2-T4 violations: Log warning, proceed
Stage 4: FixValidator
MUST spawn bulwark-fix-validator agent via Task tool:
Task(
subagent_type="bulwark-fix-validator",
model="sonnet",
prompt="GOAL: Validate the fix against the debug report...
CONTEXT:
Debug Report: logs/debug-reports/{issue-id}-{timestamp}.yaml
Fix Applied: {description of changes}
Tests Added: {if any}
..."
)Input: Debug report path, fix details, test details
Output: Validation report at logs/validations/fix-validation-{issue-id}-{timestamp}.yaml
Stage 5: CodeReviewer
MUST spawn general-purpose agent via Task tool:
Task(
subagent_type="general-purpose",
model="sonnet",
prompt="GOAL: Review the fix for correctness, completeness, and safety.
CONSTRAINTS: Do NOT modify any files. Review only.
CONTEXT:
debug_report: logs/debug-reports/{issue-id}-{timestamp}.yaml
fix_applied: {description of changes from Stage 2}
tests_added: {from Stage 3, if any}
validation_results: {from Stage 4}
OUTPUT: Approval decision (approved: true/false) with concerns and recommendations."
)Approval Criteria:
- Fix addresses root cause from debug report
- Tests verify the specific bug scenario
- No new issues introduced
- Validation confidence is acceptable (high or medium with justification)
Loop Handling
If rejected and iterations < 3:
- Return to Stage 1 with feedback
- Include previous validation results
If rejected and iterations >= 3:
- Escalate to user
- Summarize all attempts
Progress Reporting
After each stage, report progress to user:
Stage 1 (IssueAnalyzer): Complete
- Debug report: logs/debug-reports/AUTH-001-20260120.yaml
- Root cause: {summary}
- Complexity: {low|medium|high}
Stage 2 (FixWriter): Complete
- Files modified: {list}
- Fix: {brief description}
Stage 3 (TestWriter): {Complete|Skipped}
- Tests added: {count or "existing tests sufficient"}
Stage 4 (FixValidator): Complete
- Confidence: {HIGH|MEDIUM|LOW}
- Recommendation: {proceed|revise}
Stage 5 (CodeReviewer): Complete
- Decision: {Approved|Rejected}Error Handling
| Error | Action |
| IssueAnalyzer fails to identify root cause | Report to user, ask for more context |
| Tests cannot be executed | FixValidator uses manual validation strategy |
| FixValidator confidence is LOW | Escalate to user with details |
| Max iterations reached | Summarize attempts, ask user for guidance |
Related Resources
| Resource | Location |
| Pipeline definition | pipeline-templates/references/fix-validation.md |
| IssueAnalyzer agent | agents/bulwark-issue-analyzer.md |
| Implementer agent | agents/bulwark-implementer.md |
| FixValidator agent | agents/bulwark-fix-validator.md |
| Issue debugging skill | issue-debugging/SKILL.md |
Note: Paths are relative to your skills/agents directory (either skills/ or .claude/skills/).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

