debugging-methodology

Diagnose software defects using hypothesis-driven experiments, bisection, and structured instrumentation.

Updated Dec 29, 2025
One-click install
npx skills add https://github.com/snoodleboot-io/discrecontinual_equations --skill debugging-methodology-snoodleboot-io
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: debugging-methodology
Source: https://github.com/snoodleboot-io/discrecontinual_equations/tree/main/.claude/skills/debugging-methodology
Command: npx skills add https://github.com/snoodleboot-io/discrecontinual_equations --skill debugging-methodology-snoodleboot-io

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Debugging often devolves into random code changes, shotgun edits, and re-testing dead theories for hours. This Skill replaces guesswork with a disciplined scientific method: observe facts, form falsifiable hypotheses, run the cheapest discriminating experiment, and keep a written log so no theory is tested twice. ## Core Features & Use Cases - Diagnostic Loop & Experiment Design: Enforces fact/hypothesis/test/result logging and one-variable-per-experiment discipline so fixes are verified by prediction, not luck. - Binary Search Over Space and Time: Covers midpoint isolation across system components and git bisect run automation to locate regressions in logarithmic time. - Specialized Techniques: Guidance for reading stack traces to the deepest owned frame, shrinking reproductions, resolving "works on my machine" environment diffs, choosing between debuggers, logging, tracing, and dumps, and handling heisenbugs without masking them. - Use Case: A production endpoint starts returning 500s after a deploy. Use this Skill to bisect the request path, build a minimal deterministic repro, identify the null-variant data shape as the cause, and commit the shrunken case as a regression test. ## Quick Start Help me debug this failing checkout endpoint using a systematic hypothesis-driven approach instead of guessing at fixes.

Frequently Asked Questions about debugging-methodology

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug a production bug systematically?▼

Systematic debugging follows a loop: record observed facts, form a falsifiable hypothesis, design the cheapest experiment that could disprove it, and update based on results. Keep a written fact/hypothesis/result log so you never re-test a dead theory hours later.

How do I use git bisect to find a regression?▼

Run git bisect start, mark the broken commit as bad and a known-working commit as good, then test each midpoint. Automate it with git bisect run and a script whose exit code is 0 for good and non-zero for bad, using exit 125 to skip untestable revisions.

When should I use a debugger versus logging or tracing?▼

Use an interactive debugger for fast local reproductions with tangled state, structured logging for production systems that cannot pause, and distributed tracing for latency or causality across services. For hangs use thread dumps, and for hard crashes use core dumps with post-mortem debugging.

Why does my bug disappear when I add logging?▼

This is a heisenbug: instrumentation perturbs timing or memory layout, hiding races or uninitialized memory. Observe externally with tracing or packet capture, use sanitizers and race detectors, and increase concurrency pressure rather than masking the bug with sleeps.

How do I fix a bug that only fails on one machine?▼

Treat it as a controlled experiment: enumerate differences in runtime versions, lockfiles, environment variables, data, config, locale, and network between the passing and failing systems. Then bisect the difference by moving one axis at a time until the working machine breaks.

What are common debugging anti-patterns to avoid?▼

Avoid changing code to see what happens, making several changes at once, reading only the top line of a stack trace, and adding sleeps to hide races. State a hypothesis before editing, change one variable per experiment, and verify fixes by prediction rather than symptom disappearance.