← All skills
loop-breaker · Claude Code skill

Stop Claude Code going in circles on a bug

Gets a stuck session out of a loop: stop editing, reproduce the failure by hand, test every assumption, prove the root cause with evidence, and hand off to a fresh session when the context itself is the problem.

Install just this skill

From your terminal, in one command:

claude plugin marketplace add iampreetdave-max/agent-skills && claude plugin install loop-breaker@iampreetdave-skills

Or from inside Claude Code:

/plugin marketplace add iampreetdave-max/agent-skills
/plugin install loop-breaker@iampreetdave-skills

Or without the plugin system (macOS, Linux or Git Bash):

git clone --depth 1 https://github.com/iampreetdave-max/agent-skills /tmp/agent-skills && mkdir -p ~/.claude/skills && cp -r /tmp/agent-skills/skills/loop-breaker ~/.claude/skills/

Restart Claude Code afterwards. On Windows PowerShell 5, use ; instead of &&. Remove it with claude plugin uninstall loop-breaker@iampreetdave-skills.

Use it

It loads by itself when what you ask matches, for example:

Or call it directly with /loop-breaker:loop-breaker. Installed from a pack, the pack name comes first, for example /all-skills:loop-breaker.

What it does

  1. Stops editing and lists every change made during the loop, offering to revert the unproven ones.
  2. Reproduces the failure itself from a clean state and captures the exact output.
  3. Writes down every assumption as VERIFIED or ASSUMED, then tests each one with a command.
  4. Proves the root cause (what, where at file:line, why, with evidence) before changing any code.
  5. If still stuck, writes a HANDOFF.md so a new session, ideally on a different model, starts from the reproduction.

Needs

Nothing extra. Also in all-skills, senior-pack, student-pack. Read the full instructions in SKILL.md on GitHub.