bug-debugger

bug-debugger is a skill for Claude Code, Codex from khalilbenaz/claude-skills-collection. It costs 112 tokens per session (1,312 once invoked), scanned A, original, MIT.

A structured guide for diagnosing software bugs, crashes, errors, and unexpected behavior. It starts by collecting the error, expected result, reproduction details, recent changes, and environment information before ranking possible causes.

In plain words
What is it for?
Use it to investigate stack traces, HTTP failures, TypeErrors, null values, crashes, configuration problems, and regressions after a change or deployment.
Why use it?
It reduces guesswork by separating observed facts from hypotheses and focusing investigation on reproducible evidence.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to investigate stack traces, HTTP failures, TypeErrors, null values, crashes, configuration problems, and regressions after a change or deployment.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/khalilbenaz/claude-skills-collection/bug-debugger
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.

Any agent
npx skills add khalilbenaz/claude-skills-collection --skill bug-debugger
Clone the repo
git clone --depth 1 https://github.com/khalilbenaz/claude-skills-collection

Made for: Claude Code, Codex.

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 bug-debugger

README.md
[![agentmods](https://agentmods.dev/badge/skills/khalilbenaz/claude-skills-collection/bug-debugger/github.svg)](https://agentmods.dev/skills/khalilbenaz/claude-skills-collection/bug-debugger)
Your own site
<a href="https://agentmods.dev/skills/khalilbenaz/claude-skills-collection/bug-debugger"><img src="https://agentmods.dev/badge/skills/khalilbenaz/claude-skills-collection/bug-debugger/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for bug-debugger

Your own site · 80×15
<a href="https://agentmods.dev/skills/khalilbenaz/claude-skills-collection/bug-debugger"><img src="https://agentmods.dev/badge/skills/khalilbenaz/claude-skills-collection/bug-debugger.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 112 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,312 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00112 $0.01312
Opus 5 $0.00056 $0.00656
Sonnet 5 $0.00022 $0.00262
Haiku 4.5 $0.00011 $0.00131

Measured 9d ago against content hash 2440044def4e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

bug-debugger 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 9d 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.

dev-skills/bug-debugger/SKILL.md · 159 lines

How it starts

The opening of the file, as written. The whole thing — 159 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Bug Debugger

Étape 0 — Collecter le contexte minimal

Avant toute hypothèse, s'assurer d'avoir :

Info Exemples
Message d'erreur complet stack trace, code HTTP, errno
Comportement attendu vs observé "devrait retourner 200, retourne 500"
Reproductibilité toujours / parfois / en prod seulement
Dernière modification commit, déploiement, changement config
Environnement OS, version runtime, variables d'env

Si un de ces éléments manque et bloque le diagnostic → demander uniquement ce qui est nécessaire, pas tout à la fois.


Étape 1 — Lire l'erreur sans sauter aux conclusions

TypeError: Cannot read properties of undefined (reading 'id')
    at getUserName (user.js:42:18)
    at processRequest (api.js:17:5)
  • Lire le type d'erreur : TypeError, NullReferenceException, SIGSEGV
  • Localiser le premier frame applicatif (ignorer les frames de libs tierces).
  • Identifier l'opération qui échoue : accès propriété, appel fonction, cast, IO…

Étape 2 — Formuler 3 hypothèses classées par probabilité

Format attendu :

  1. (Probable) user est undefined car la DB ne retourne rien pour cet ID → vérifier avec console.log(user) avant la ligne 42.
  2. (Possible) La fonction est appelée avant que la promesse soit résolue → ajouter await.
  3. (Moins probable) Race condition sur un cache partagé → vérifier si ça arrive en parallèle.

Règle : ne pas proposer plus de 3 hypothèses sans validation intermédiaire.


Étape 3 — Vérification rapide par hypothèse

JavaScript/TypeScript

// Inspecter sans modifier le flux
console.log('[debug] user:', JSON.stringify(user, null, 2));
// Vérifier le type exact
console.log('[debug] typeof user:', typeof user, user instanceof Object);

Python

import pprint
print('[debug] user:', pprint.pformat(user))
# Ou avec breakpoint natif (Python 3.7+)
breakpoint()

.NET / C#

// Ajouter un point de log avant la ligne incriminée
_logger.LogDebug("user={User}", JsonSerializer.Serialize(user));
// Ou utiliser le debugger avec Watch sur l'expression

Read the full file on GitHub · 159 lines

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. 9d ago First seen · 159 lines · 112 tokens per session scan A 2440044def4e

Subscribe to this mod's changes

bug-debugger is a skill published in the GitHub repository khalilbenaz/claude-skills-collection (22 stars, last pushed 19d ago), licensed MIT. It adds 112 tokens to every session and 1,312 once invoked, about $0.0006 per session on Opus 5. 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.