google/dev-bug-review
Triage and resolve incoming bug reports one by one. Use when the user brings in one or more bug reports (from a tracker, a dump, a "here are three bugs" paste, etc.) and expects each to be confirmed, the proposed fix evaluated or pushed back on, implemented only after agreement, then committed with a changelog entry. Enforces confirm-before-fixing, push-back-with-reasoning, and per-bug commit discipline. Do NOT use for ad-hoc single-bug debugging where the user hasn't framed it as a review queue -- use dev-debugging for that.
npx skills add https://github.com/google/capsem --skill dev-bug-review
A disciplined workflow for working a queue of bug reports. One bug at a time. No skipping steps. No batching.
For every incoming bug report, execute these five phases in order. Do not proceed to the next phase without the previous one's output.
If there are N bugs, you run this loop N times. Do not try to land all bugs in one commit unless the user explicitly says so.
Before writing any code, prove the bug is real and that you understand it.
just exec "<cmd>" that demonstrates the issue, a session DB inspection, a screenshot, a log snippet.ServiceInstance, e2e RealService, MCP conftest helper) archive their tmp_dir to test-artifacts/<timestamp>-<worker>-<nodeid>/<tmp-basename>/ on failure. The stderr of the failing test has an ARTIFACT: preserved ... -> test-artifacts/... line with the exact path. Inside: service.log, sessions/<vm-id>/process.log, sessions/<vm-id>/serial.log, sessions/<vm-id>/session.db, logs/gateway.log. These are the authoritative evidence for "VM didn't boot", "provision hung", or "exec timed out" style reports -- read them before accepting any root-cause theory. See /dev-debugging Step 2 for the layout. If the artifact doesn't exist, ask the user to rerun (or run it yourself) so one gets captured.Output for this phase is a short statement: *what the bug is, where it lives, and the evidence*. Do not proceed silently.
The report usually arrives with a proposed fix. Treat it as a hypothesis, not an order (see memory: "Push back on proposed fixes").
Evaluate the proposed fix against:
/dev-debugging "Fix the pattern, not the instance".If the proposed fix is wrong or incomplete, push back with reasoning. State what you'd do instead and why. Do not silently "improve" the fix -- name the disagreement so the user can weigh in.
If the proposed fix is correct, say so plainly. Do not pad with fake alternatives.
Stop and wait. Do not start editing code until the user confirms the plan for this specific bug. A single "sounds good" covers this one bug, not the whole queue.
Auto mode does not override this. Agreement gates on the fix plan are a feature, not an interruption -- the user explicitly asked for a review workflow.
Fixes land test-first. No exceptions.
capsem_core::poll::poll_until exists, hand-rolled 0o600 when pty_log::open_append exists, a vec![...] a clippy-lint away, a patient: bool where an enum self-documents), fix it in the same commit. Do NOT ship a minimal diff on top of a bug that was caused by the duplication -- that's how the same bug class reappears in a new location. Rules: (a) touch only code the fix itself motivates, (b) check existing primitives first (grep for poll_until, capsem_core::, shared helpers) before hand-rolling anything, (c) call out each cleanup in the summary so it's explicit, not silent. "Also fixed while I was here: X, Y, Z." If the cleanup is large enough that it'd dominate the diff or obscure the bug fix, split it into a sibling commit in the same review.cargo check -p <crate> + targeted cargo testjust testpnpm run check (fail-on-warnings) + pnpm test where relevantjust exec "capsem-doctor -k <category>" or the targeted diagnosticpython3 scripts/check_session.pyWrite a summary back to the user before committing:
Then commit per project rules (CLAUDE.md "Commits"):
CHANGELOG.md under ## [Unreleased] in the same commit as the fix. Write from the user's perspective under ### Fixed.git add -A.fix: <one-line subject>. Body can expand on root cause.Co-Authored-By trailers.Then move to the next bug in the queue and repeat from Phase 1.
/dev-debugging -- the methodology for a *single* bug investigation (reproduce, diagnose, fix). Bug review composes debugging across a queue with extra gates (confirm, push back, per-bug commit)./dev-sprint -- for multi-change features. Bug review is lighter weight: no sprint dir, no tracker.md, one commit per bug./dev-testing -- the testing gates invoked in Phase 4.Take google/dev-bug-review from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.