Debug

cyrusagents/cyrus/skills/debug

by cyrusagents9cb20212dfb0caec7fc44a4688d41829589087bcNo license850 starsListed Oct 9, 2026Updated Oct 9, 2026Repository updated today

Full debugging workflow — reproduce the bug with a focused check, perform root cause analysis, then implement a minimal fix.

Instructions onlySoftware Development
AI-generated overview

Guides a structured debugging workflow: reproduce a bug, find its root cause, then apply a minimal verified fix.

What it does
This skill provides a two-phase debugging procedure for a reported issue. Phase one investigates the bug report, traces the symptom to its source, identifies the root cause, reproduces the error with the smallest useful check, and documents the cause and reproduction steps. Phase two plans and implements a minimal targeted fix, then repeats the reproduction and runs relevant existing checks to verify it.
When to use it
Use it when a specific bug has been reported and needs to be diagnosed and fixed. It suits situations where the cause is unknown and a disciplined reproduce-then-fix approach is wanted, rather than broad refactoring or unrelated improvements.
Requirements
No scripts or special tooling are required; it is an instructions-only workflow. It assumes access to the codebase and the ability to run commands or tests to reproduce the issue.

Debug

Debug a reported issue using a structured reproduction-then-fix approach.

Phase 1: Reproduction & Root Cause Analysis

  1. Investigate — Analyze the bug report for key symptoms and error messages
  2. Trace — Search the codebase for error occurrence patterns, trace from symptom to source
  3. Root cause — Identify the root cause through data flow analysis and edge case checking
  4. Reproduce — Reproduce the exact error with the smallest useful check (a command, dry run, manual flow, or automated test)
  5. Document — Clearly document the root cause and reproduction steps

Phase 2: Fix Implementation

  1. Plan — Analyze the optimal fix approach based on root cause, check for similar fixes in the codebase
  2. Implement — Make the minimal, targeted fix that addresses the root cause
  3. Verify — Repeat the reproduction to confirm the fix and run relevant existing checks. Follow verify-and-ship for proportionate scope; add a regression test only when the concrete failure warrants durable coverage

Principles

  • Minimal changes — Fix the bug, nothing more
  • Targeted — Only touch affected code paths
  • Verified — Confirm the reproduction succeeds after the fix and preserve relevant existing safeguards; a new test file is not mandatory
  • No unrelated improvements — Stay focused on the specific bug

Source and attribution

Source:cyrusagents/cyrusinskills/debugat commit9cb2021

License: No license

Content belongs to its original authors. SourceWeft indexes it from a public repository.

Report or request removal