diagnosing-bugs

Diagnose hard bugs and performance regressions through a structured six-phase feedback-loop workflow.

2|Updated Jul 11, 2026
One-click install
npx skills add https://github.com/MoofonLi/dev-ready --skill diagnosing-bugs-moofonli
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: diagnosing-bugs
Source: https://github.com/MoofonLi/dev-ready/tree/main/.agents/skills/diagnosing-bugs
Command: npx skills add https://github.com/MoofonLi/dev-ready --skill diagnosing-bugs-moofonli

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? Hard bugs and flaky performance regressions resist casual code reading; without a reproducible failing signal, debugging devolves into guessing. This Skill enforces a disciplined diagnosis loop that builds a tight, deterministic reproduction before any hypothesis is tested. ## Core Features & Use Cases - Feedback Loop Construction: Builds a red-capable, deterministic, fast reproduction command using failing tests, curl scripts, headless browsers, replayed traces, fuzz loops, or bisection harnesses. - Structured Six-Phase Process: Guides reproduction and minimization, ranked falsifiable hypothesis generation, single-variable instrumentation with tagged debug logs, regression-test-first fixing, and cleanup with post-mortem. - Non-Deterministic Bug Handling: Raises reproduction rates for flaky bugs via looped triggers, parallelism, stress, and timing injection until the bug is debuggable. - Use Case: A user reports an intermittent 500 error on the export endpoint. The Skill drives creation of a curl-based loop that reproduces the failure, minimizes the scenario, tests ranked hypotheses one variable at a time, and lands a regression test with the fix. ## Quick Start Ask the agent to diagnose the bug where the export button throws an error, and have it build a failing reproduction loop before proposing any fix.

Frequently Asked Questions about diagnosing-bugs

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

FAQPage Schema
How to reproduce a bug before fixing it?

Build a tight feedback loop first: a failing test, curl script, CLI invocation, headless browser script, or replayed trace that goes red on the exact symptom. Then minimize the scenario by removing elements one at a time until every remaining piece is load-bearing.

What should I do when I cannot reproduce a bug at all?

Stop and say so explicitly rather than hypothesizing without a loop. Ask the user for environment access, a captured artifact like a HAR file or log dump, or permission to add temporary production instrumentation.

Why write the regression test before the fix?

Writing the regression test first confirms it actually catches the bug by watching it fail, then pass after the fix. If no correct test seam exists, that absence is itself a finding about the codebase architecture worth flagging.

How do I debug a performance regression?

For performance regressions, skip log-based probing: establish a baseline measurement with a timing harness, profiler, or query plan, then bisect against that baseline. Measure first, fix second.