work-flow-bugfix

work-flow-bugfix is a command for Claude Code from christopherlouet/claude-base. It costs 0 tokens per session (520 once invoked), scanned A, original, MIT.

A complete bug-fixing workflow that covers diagnosis, testing, coding, review, and deployment.

In plain words
What is it for?
Use it to investigate the root cause, write a failing regression test, apply a minimal fix, run quality checks, and prepare a commit or pull request.
Why use it?
It provides a repeatable path from reproducing a bug to verifying that the fix works and does not cause regressions.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/christopherlouet/claude-base/work-flow-bugfix
Clone the repo
git clone --depth 1 https://github.com/christopherlouet/claude-base

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for work-flow-bugfix

README.md
[![agentmods](https://agentmods.dev/badge/commands/christopherlouet/claude-base/work-flow-bugfix.svg)](https://agentmods.dev/commands/christopherlouet/claude-base/work-flow-bugfix)
Your own site
<a href="https://agentmods.dev/commands/christopherlouet/claude-base/work-flow-bugfix"><img src="https://agentmods.dev/badge/commands/christopherlouet/claude-base/work-flow-bugfix.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 520 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00520
Opus 5 $0.00000 $0.00260
Sonnet 5 $0.00000 $0.00104
Haiku 4.5 $0.00000 $0.00052

Measured 2d ago against content hash a6382eaed8ef, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

work-flow-bugfix scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/work/work-flow-bugfix.md · 52 lines

What it actually says

Agent WORK-FLOW-BUGFIX

Complete workflow to fix a bug, from diagnosis to deployment.

Context

$ARGUMENTS

Objective

Execute the full fix cycle: branch, diagnosis, regression test, minimal fix, verification, commit with issue reference, PR or hotfix.

Workflow

  • ISSUE (if applicable): When fixing a GitHub issue, start by retrieving it (gh issue view <n>, comments, labels) to ground the diagnosis; the commit/PR will close it via Fixes #<n>
  • BRANCH: Create branch fix/[name] from up-to-date main
  • DIAGNOSIS: Reproduce the bug, isolate the problem, identify the root cause
  • TEST: Write a failing test that proves the bug (MUST fail before the fix)
  • FIX: Implement the minimal fix (no opportunistic refactoring)
  • VERIFY: Run all tests, lint, typecheck, build, manual test
  • AUDIT: Quick review for simple bugfix (/qa:qa-review), full audit + fix loop for critical bug (/qa:qa-loop "score 90")
  • COMMIT: Format fix(scope): description with cause, solution, Fixes #issue
  • PR/HOTFIX: Normal PR or hotfix depending on urgency (critical prod bug = hotfix)

Expected output

  1. Diagnosis: Symptom, expected behavior, root cause, affected files
  2. Test: Regression test file added
  3. Fix: Minimal fix applied
  4. PR: PR URL with full description (issue, cause, solution, tests)
Agent Usage
/dev:dev-debug In-depth diagnosis
/dev:dev-tdd Generate regression tests
/qa:qa-review Quick review (simple bugfix)
/qa:qa-loop Audit + fix loop (critical bug, score 90)
/ops:ops-hotfix Critical bug in production
/work:work-commit Commit format

IMPORTANT: Always write a test that reproduces the bug BEFORE fixing it.

YOU MUST reference the issue in the commit and the PR.

NEVER refactor in a bug fix - one fix = one bug.

Think hard about the potential side effects of the fix.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 52 lines · 0 tokens per session scan A a6382eaed8ef

Subscribe to this mod's changes

work-flow-bugfix is a command published in the GitHub repository christopherlouet/claude-base (5 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 520 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.