agentleFS
andeeplusandeeplus/aplus/skills/debug/SKILL.md

debug

Skill2 starsChanged 38 days agoMITView on GitHub

Find and fix a bug at its root cause. Use for a failing test, a crash, an error, wrong output, a regression or flaky behaviour; before changing code to make a symptom go away.

192 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use add-discord, add-slack and 10 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.
  • MicrosoftSkill

    add-discord

    Add Discord bot channel integration via Chat SDK.

    Also in 11 projects that use this

  • MicrosoftSkill

    add-slack

    Add Slack channel integration via Chat SDK.

    Also in 11 projects that use this

  • +10 more from microsoft

The file

We split this skill into the rules it gives an agent

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

  • 0

    Common

    Most of the 175 edited versions we read keep these.

  • 3

    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
  1. Distinctive:

    No fix before the cause is proven.

    line 8
  2. Distinctive:

    Redact secrets: before pasting any output.

    line 12
  3. Distinctive:

    Investigate uncertainty: Test the next hypothesis when the evidence supports it.

    line 13
  4. Very specific:

    Prove it by running code: Add boundary logs when needed, tagged [DEBUG-<id>] for cleanup.

    line 21

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

Debug

No fix before the cause is proven.

Rules

  • Redact secrets before pasting any output.
  • Investigate uncertainty. Test the next hypothesis when the evidence supports it. After three failed fixes, reassess the cause and design; ask when progress needs information or a decision you cannot establish yourself.

Flow

  1. Read the whole error, stack trace included, before touching code.
  2. Build a loop that goes red: one fast, deterministic command that shows the user's exact symptom, on the surface where it happens. Run it once. A pass on another surface proves nothing. If you cannot build one, say what you tried and ask.
  3. Shrink it while preserving the symptom. For a regression with an unknown introducing commit, use git bisect run when the loop can distinguish good and bad revisions.
  4. Hypothesise. Rank plausible causes from the evidence, each falsifiable: "if X is the cause, changing Y removes the bug". Test the strongest one first, changing one thing at a time.
  5. Prove it by running code. Add boundary logs when needed, tagged [DEBUG-<id>] for cleanup. Check the observation when results surprise you. If a restart removes the symptom, investigate the state and timing it resets; the cause remains unproven.
  6. Fix where it starts, tracing the bad value to its source. Search for related instances, verify that they share the cause, fix those inside the task's scope, and report the rest. Choose the smallest durable fix using code-quality's design rules. Enforce the contract at the responsible boundary; synchronize races on the actual condition.
  7. Regression test first (testing), from the bug's scenario when it has one. Revert the fix and see it fail, restore it and see it pass. If no clean seam exists, that is the finding.
  8. Verify: re-run the original loop, the debug-tag grep comes back empty, and the commit or PR states the proven cause.

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.