agentleFS
syangasyanga/astack/skills/bug-fix/SKILL.md

bug-fix

Skill0 starsChanged 2 months agoMITView on GitHub

Reproduce a reported defect, establish its cause, implement a fix, and verify the original failure.

19 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use refactor and code-review.

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.
  • GitHubSkill

    refactor

    Surgical code refactoring to improve maintainability without changing behavior. Covers extracting functions, renaming variables, breaking down god functions, improving type safety, eliminating code smells, and applying design patterns. Less drastic than repo-rebuilder; use for gradual improvements.

    Also in 3 projects that use this

  • GoogleSkill

    code-review

    Adversarial systems, concurrency, memory-model, and architecture code review protocol. Use this skill whenever asked to review code, PRs, diffs, or branches in Filament.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 3 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 15 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Verify on the same UI, CLI, or API.

    line 16
  2. Distinctive:

    Keep the failing-before and passing-after evidence.

    line 17
  3. Distinctive:

    Use open-pr within the task's delivery scope.

    line 18

“Common” is measured: kept by at least 6 in 10 of the 15 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Bug fix

You own this task. Plan, review, verify. Delegate investigation and the fix with the available subagent tools. Review the findings and diff yourself. If delegation is unavailable, do the work directly and make the separate review pass explicit.

Be scientific. Tie each fix to runtime evidence. When evidence refutes a hypothesis, remove the experimental changes it motivated while preserving unrelated work. Ship the smallest change the evidence justifies.

  1. Reproduce the user's failure yourself through the affected UI, CLI, or API in an authorized environment. Use diagnosing-bugs phases 1 through 4 for the feedback loop, minimization, and cause. This workflow owns implementation and delivery below. Use the available control tools. If access prevents reproduction, state what you tried and the specific missing access or artifact. Continue useful investigation with unverified hypotheses clearly labeled.
  2. Narrow the cause with the diagnosis loop. Use how for the affected subsystem and why for relevant regression history. Run independent code and history inquiries in parallel when possible. Each experiment should distinguish the remaining hypotheses. Confirm the mechanism with runtime evidence before designing a fix.
  3. Plan the fix. If it crosses a function boundary, read architect first. Before implementation, follow tdd's bug-fix workflow to establish failing-before evidence at a practical test boundary, or explain the alternative check. Delegate implementation with the scope, confirmed mechanism, reproduction command, and acceptance criteria. Review the diff.
  4. Verify on the same UI, CLI, or API. Rerun the original reproduction, the regression check, and relevant adjacent checks. "Inconclusive" or a check of a different interface is not a pass. Apply diagnosing-bugs' cleanup and intermittent-failure criteria.
  5. Keep the failing-before and passing-after evidence. Follow sequence-verifiable-units for ordered commits when the work has several units. Run review-pr in fix-and-review mode before delivery.
  6. Use open-pr within the task's delivery scope. Honor a request for local edits only. Merging is a separate action.

For a unit in a multi-phase plan, follow the shared execution-state convention. Reuse its store. Delegated workers return evidence to the coordinator. For a session transfer, read handoff. Include the reproduction command, hypotheses ruled out, current instrumentation, and evidence paths.

Reply: what was broken, root cause, fix, and verification. Include redacted failing-before and passing-after output, or state which evidence is unavailable.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.