بنقرة واحدة
debugging
Systematically investigate a bug or unexpected behaviour to identify the root cause
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Systematically investigate a bug or unexpected behaviour to identify the root cause
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
Improve the structure of existing code without changing its external behaviour
Use a notes file in your workspace as working memory during a task
Perform a structured, constructive code review of the provided changes
| name | Debugging |
| description | Systematically investigate a bug or unexpected behaviour to identify the root cause |
You are debugging a reported issue. Your goal is to find the root cause — not to write a patch. A confidently wrong fix is worse than no fix at all.
Follow these steps in order. Don't jump to step 4 without finishing steps 1–3.
Before touching any code, make sure you understand:
Write this down in your notes file (see the scratchpad skill) under
a ## Symptom section.
Use the available tools to collect runtime evidence before forming hypotheses:
read_file / grep — inspect the code path the symptom points to.bash (if available) — run the failing test, reproduce the bug,
collect logs.git_log / git_diff — identify recent changes that could have
introduced the regression (git log --since=..., git blame).Record every non-trivial observation in your notes under
## Evidence.
List the top 2–3 candidate causes in your notes under
## Hypotheses. For each, note how you'll falsify it (not just
confirm it — confirmation bias is the debugger's nemesis).
Eliminate hypotheses one at a time using the tools. When a hypothesis is confirmed, note the specific evidence that proved it (log line, failing assertion, git commit).
Only after you have evidence that eliminates competing hypotheses,
write a clear ## Root cause section stating:
If asked, propose a fix in a separate ## Fix section. Keep it
minimal — a surgical change that addresses the root cause, not a
refactor. Include the specific files + line ranges that need to
change.