/claudops:dbg [bug description or error message]from Claudops
Runtime debugging skill that instruments code, reproduces issues, and finds root causes using logged evidence. Activated when users paste errors, stack traces, or describe unexpected behavior.
Ships in Claudops. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
If
.claude/skills/dbg/SKILL.md.disabledexists, stop before reading a fallback. Project configuration: If the current project contains.claude/skills/dbg/SKILL.md, read and apply it instead of this bundled default. The project copy is the capability source of truth. Repository context: Read../setup/references/task-context.mdwhen resolving a task, project commands, named agent roles, or legacy.claude/resource paths. Use repository evidence and applicable project instructions; a missing local workflow copy does not require setup. Resolve bundled resources from the installed skill, never from the target cwd.
Announcement: Begin with: "I'm using the dbg skill for runtime debugging."
Find root cause using runtime evidence, not guesses. Never speculate about code paths you have not opened or behavior you have not logged. The investigate-then-fix ordering exists because guessed fixes mask bugs that reappear in production; logged-and-verified fixes do not. Instrument, reproduce, analyze, confirm, and only then edit.
Resolve the task with ../setup/references/task-context.md before instrumentation. Keep the
project-relative debug log for runtime evidence, link it (and any bug report) from the selected task
record, and record the root cause, verification result, current state, and next action there. A
standalone read-only diagnosis may return a proposed path without creating a task file.
Use a project-relative debug log file:
.debug/debug.log (relative to project root).debug/ directory if it doesn't existEach log entry (NDJSON — one JSON object per line):
{ "sessionId": "S1", "runId": "run1", "hypothesisId": "A", "location": "file.ts:42", "message": "desc", "data": {}, "timestamp": 1234567890 }
TypeScript / JavaScript (file-based):
import { appendFileSync, mkdirSync } from 'fs';
mkdirSync('.debug', { recursive: true });
// #region dbg
appendFileSync('.debug/debug.log', JSON.stringify({ location: 'file.ts:LINE', message: 'desc', data: { key: val }, timestamp: Date.now(), sessionId: 'S1', runId: 'run1', hypothesisId: 'A' }) + '\n');
// #endregion
Python:
# #region dbg
import json, time, os
os.makedirs('.debug', exist_ok=True)
with open('.debug/debug.log', 'a') as f:
f.write(json.dumps({"location": "file.py:LINE", "message": "desc", "data": {}, "timestamp": time.time(), "sessionId": "S1", "runId": "run1", "hypothesisId": "A"}) + "\n")
# #endregion
Adapt the pattern for other languages. Always wrap instrumentation in #region dbg / #endregion markers for easy cleanup.
{ token: "<redacted:string:len=42>" }),
not the value.Skip this step if the user supplied a reproducible trigger, a stack
trace, or an error message — proceed to Step 1. Use AskUserQuestion
only when you cannot name a concrete first hypothesis without more
input. The missing pieces worth asking about are: exact repro steps,
expected vs actual, and environment (not general "tell me more").
Before generating hypotheses, gather fast context:
git log --oneline -10 -- <path>This often narrows the search space dramatically or reveals trivial causes that don't need full instrumentation.
Generate 2–5 precise hypotheses, scaled to bug complexity. For a trivial bug with a clear suspect from Step 1, two hypotheses (the suspect and one alternative) are enough. For a cross-service race condition, use the full 5. Be specific — each hypothesis should point to a different subsystem or failure mode.
Add log points to test all hypotheses in parallel. Keep them minimal and localized. Use the language-appropriate snippet from above.
Before asking the user to reproduce:
.debug/debug.log)After the user confirms they've reproduced the issue, read and analyze the log file.
Read the NDJSON log file and evaluate each hypothesis:
Implement a fix only when logs confirm the root cause. Do not remove instrumentation yet — it's needed for verification.
Ask user to reproduce again. Compare pre-fix vs post-fix logs:
runId: "post-fix"For non-trivial bugs (logic errors, race conditions, architectural issues), create a bug report only when it has an independent review/tracker purpose; otherwise keep the root cause in the selected task record:
.claude/docs/templates/bug-report-template.md<resolved-task-root>/bug-report-[bug-name].md (preserve an existing legacy path)Skip for trivial fixes (typos, missing imports, config errors) — a good commit message suffices.
After verified success:
#region dbg / #endregion instrumentation blocks/code-analysis/fci/srWhat SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub alexandrbasis/claudops --plugin claudops40 skills in this plugin
/analyzeCompare a task's discovery or product requirements with its tech decomposition and report traceability gaps. Use when asked to 'analyze consistency', 'check alignment', 'verify spec matches plan', 'traceability check', 'spec drift', 'are my docs aligned', or after /ct completes to verify the plan covers the requirements. `/ct` may invoke this check when traceability is material; otherwise it remains an explicit read-only command. NOT for code review (use /sr), NOT for code analysis (use /code-analysis), NOT for debugging (use /dbg)./antigravity-cliRun Google Antigravity CLI (agy) for web-grounded research, cross-AI review, or validation when those capabilities are explicitly needed or another skill delegates to agy. One-shot only; do not select it for an ordinary review without an explicit provider choice./Other plugins' skills for the same job