Skip to content
backnotprop avatar

Principle Fix Root Causes

Trace each bug to its first wrong decision and fix it there, not at the symptom.

CCM score
62 of 100
skills.sh installs
13.8K
GitHub stars
5.4K
last updated
Nov 29, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers root-cause debugging: reproduce first, ask "why" until the answer is a wrong decision in the code, then instrument and read actual state
  • Asks whether the triggering state is legitimate; handles legitimate states where the code broke, and finds the producer of illegitimate ones
  • Warns that guards, retries, swallowed errors, clamped values, and discarded state usually hide bugs instead of fixing them
  • Directs fixing the pattern across every place with the same fault, and proposing a cheap always-on signal when the diagnosis took a deep dig

Install

$ npx -y skills add backnotprop/pstack --skill principle-fix-root-causes -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Fix Root Causes

Fix the fault, not the place where it surfaced. The root cause is the first place the system did something it should not do, or failed to handle a state it should handle.

  • Reproduce first. Ask "why" until the answer is a wrong decision in the code. When stuck, instrument and read the actual state.
  • Ask whether the state that triggered the symptom is legitimate. If it is, handle it where the code broke. If it should never exist, a check there hides the bug, so find what produced it. Guards, retries, swallowed errors, clamped values, and discarded state are the usual ways to hide a bug.
  • Fix the pattern, not the instance. Find every place with the same fault.
  • If the deciding fact took a deep dig, propose the cheap, always-on signal that would have shown it at first look.

Details

Repository
github.com/backnotprop/pstack
Category
Debugging
First seen
Nov 29, 2026

More from backnotprop/pstack

All 7

Similar to Principle Fix Root Causes

More Debugging