debug-detective
Skill0 starsChanged 6 days agoMITView on GitHub
Find the root cause of a bug, crash, error message or failing test, then fix it. Use when the user says "this is broken", "why does this fail", "I get this error", "the test is failing", "it worked yesterday", or pastes a stack trace.
5 other projects use a version of this.
Adopted by
Most recently taken up by
- jaskirat1616/grok-skillstheir own version, first seen Nov 1, 2026
- JayRHa/agent-skillstheir own version, first seen Oct 15, 2026
- JayRHa/AgentSkillstheir own version, first seen Jun 9, 2026
- Noumenon-ai/noumenon-free-starter-packtheir own version, first seen Apr 7, 2026
- xmqywx/claude-code-skillstheir own version, first seen Apr 2, 2026
Other versions5 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 5
- jaskirat1616/grok-skills★ 22same name
- JayRHa/agent-skills★ 12same name
- JayRHa/AgentSkills★ 12same name
- xmqywx/claude-code-skills★ 2same name
- Noumenon-ai/noumenon-free-starter-pack★ 0same name
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 repository24 other files it gives its agents.
- api-docsSkill
- changelogSkill
- ci-failure-fixSkill
- code-reviewSkill
- commit-messageSkill
- competitor-analysisSkill
- data-analystSkill
- dependency-upgradeSkill
- dockerizeSkill
- email-replierSkill
- eval-promptSkill
- incident-postmortemSkill
- meeting-notesSkill
- migration-safetySkill
- pr-descriptionSkill
- product-specSkill
- readme-writerSkill
- refactor-safelySkill
- research-briefSkill
- security-checkSkill
- seo-articleSkill
- sql-helperSkill
- support-replySkill
- write-testsSkill
The file
We split this skill into the rules it gives an agent
8 rules. 0 are common, 7 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 5 edited versions we read keep these.
7
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 18
Read the whole message and the first frame in the project's own code.
- Very specific: line 23
If it used to work: git log --oneline -20 -- <relevant paths>, recent dependency updates, config or data changes.
- Distinctive: line 27
Write 2-3 hypotheses ranked by likelihood.
- Distinctive: line 28
Test the cheapest one first: print a value, add an assertion, run with a debugger, call the function with the failing input.
- Distinctive: line 31
Stop rule: if three hypotheses fail, step back.
- Distinctive: line 37
Add a test that fails before the fix and passes after.
- Distinctive: line 38
Search for the same pattern elsewhere (git grep) and list other places with the same bug.
- Distinctive: line 44
Leave debug prints, breakpoints or temporary flags behind.
“Common” is measured: kept by at least 6 in 10 of the 5 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
Systematic debugging
Work from evidence. Every edit you make should either gather information or fix a cause you can explain.
1. Reproduce
- Get the exact command, input, environment and the full error output (not a summary). Run it yourself if you can.
- Make the reproduction as small and fast as possible: a single test, a script, one request with curl.
- Cannot reproduce? List the differences between your run and theirs (env vars, versions, data, OS, config, cache, timezone) and ask for the missing ones. Do not guess-fix a bug you have not seen.
2. Read the error literally
- Read the whole message and the first frame in the project's own code. Look at the line, and the values that reach it.
- For "works on my machine", compare versions: lockfile, runtime (
node -v,python --version), env vars, data.
3. Ask what changed
If it used to work: git log --oneline -20 -- <relevant paths>, recent dependency updates, config or data changes. If there is a known good commit and a quick check, use git bisect (git bisect run <command> when the check is scriptable).
4. Hypothesize and test
- Write 2-3 hypotheses ranked by likelihood. For each, name the observation that would confirm or rule it out.
- Test the cheapest one first: print a value, add an assertion, run with a debugger, call the function with the failing input.
- Change one thing at a time. Revert any change that did not help before trying the next.
Stop rule: if three hypotheses fail, step back. Re-check your assumptions (is the code you are reading the code that runs? stale build, wrong branch, cached module, different config file), and share what you have ruled out with the user.
5. Fix the cause
- State the cause in one sentence: "X fails because Y, introduced in Z".
- Fix it where it originates, not where it surfaces.
- Add a test that fails before the fix and passes after. Run the related test suite.
- Search for the same pattern elsewhere (
git grep) and list other places with the same bug.
Do not
- Silence the symptom: empty catch blocks,
|| true, skipping or deleting the test, longer timeouts, retries around a deterministic failure. - Stack several speculative fixes and keep whichever "works".
- Leave debug prints, breakpoints or temporary flags behind. Remove them before reporting.
Report
- Root cause (one sentence) and the evidence that proves it.
- The fix (files changed) and the test that covers it.
- Other places affected, and anything you could not verify.
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.

