From nexus-agents
Fixes bugs following project standards with a structured triage process. Useful for defect fixing, debugging, or resolving reported problems, with clear stop-the-line and root-cause analysis protocols.
How this skill is triggered — by the user, by Claude, or both
Slash command
/nexus-agents:bug-fixThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
<!--
Full workflow: CONTRIBUTION_GUIDE.md
When a test, build, or lint fails mid-flow — before making any more changes:
Rationale: failures compound. A bug unresolved at step N makes every change N+1…N+k incorrect. We observed this in #1871 (consensus_vote silent hang) — the symptoms looked like adapter timeouts, the cause was missing overall-deadline race.
Run this order before "Implement fix." Skipping steps produces symptom-level patches that regress.
pnpm lint && pnpm typecheck && pnpm test plus any integration/smoke test for the affected area.Debugging tempts four recurring shortcuts. Each is a trap.
| Excuse | Counter |
|---|---|
| "I know what the bug is" | Unverified guesses resolve only ~70% of the time. Reproduce first — the cost of confirming is minutes; the cost of a wrong fix is hours plus a regression. |
| "The failing test must be wrong" | Sometimes true, but verify against the spec before changing the test. A test asserting correct-but-inconvenient behavior gets "fixed" to assert the bug. |
| "It works on my machine" | Environment is a variable. Diff Node version, env vars, lockfile drift, CI container, clock/timezone, file system case sensitivity. |
| "This is flaky, ignore it" | Flaky = the test is exposing a real race/ordering/timing bug. Fix the intermittency or understand why it happens. .skip with a TODO is a ticking debt. |
Create/verify GitHub issue with reproduction steps
gh issue list --state open
gh issue create --title "bug: [description]" --label "bug"
Write failing test that demonstrates the bug
pnpm test -- --watch
Implement fix — minimal changes, don't refactor surrounding code
Verify test passes
pnpm lint && pnpm typecheck && pnpm test
Check for similar bugs elsewhere
# Search for similar patterns in codebase
Create PR
git commit -m "fix(scope): description
Closes #<issue>
Co-Authored-By: Claude Opus 4.6 <[email protected]>"
gh pr create --title "fix(scope): description" --base main
pnpm lint && pnpm typecheck && pnpm test passesmain without the fixnpx claudepluginhub nexus-substrate/nexus-agentsFixes bugs with a structured workflow: investigate root cause, apply minimal fix, add regression tests, verify with test adequacy and code review gates.
Reproduce-first bug repair workflow with regression protection. Gathers context, diagnoses root cause, and applies code quality and testing guardrails. Activated by commands like 'fix this bug' or 'debug this'.
Step-by-step bug fix workflow: diagnose root cause, implement minimal fix, write regression test. Use when fixing bugs or working on bug report issues.