Agent skill
debug
Systematic debugging workflow: reproduce, isolate, fix, verify
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/debug-coakenfold-p-100226
SKILL.md
Debugging Workflow
PROSE constraints: Reduced Scope (narrow the problem systematically) + Progressive Disclosure (gather context incrementally).
Phase 1: Understand the Problem
- Parse
$ARGUMENTSfor error messages, stack traces, or symptom descriptions - Search the codebase for relevant code paths
- Read related test files to understand expected behavior
Phase 2: Reproduce
- Identify a minimal reproduction path
- Run relevant tests to confirm the failure:
npm test -- [relevant-test] - If no test exists, create one that demonstrates the bug
Phase 3: Isolate
- Trace the execution path from symptom to root cause
- Check recent changes:
git log --oneline -20 - Narrow scope — identify the single function or condition causing the issue
- State the root cause clearly before proceeding
Validation Gate
STOP: Present the root cause analysis and proposed fix. Wait for confirmation.
Phase 4: Fix
- Make the minimal change that fixes the root cause
- Don't refactor surrounding code — fix the bug only
- Update or add a test that would have caught this bug
Phase 5: Verify
- Run the failing test to confirm it passes:
npm test -- [test-file] - Run the full test suite to check for regressions:
npm test - Run the linter:
npm run lint
Output Summary
## Bug Fix: [title]
### Root Cause
[What was wrong and why]
### Fix
[What was changed]
### Files Modified
- [file] — [change description]
### Verification
- [test] — passes
- Full suite — no regressions
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?