investigate

Diagnose bugs through systematic root cause investigation before applying verified fixes.

Updated Mar 26, 2026
One-click install
npx skills add https://github.com/LGJ-Jonathan/Jonathan_Global_Claude_Skills --skill investigate-lgj-jonathan
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: investigate
Source: https://github.com/LGJ-Jonathan/Jonathan_Global_Claude_Skills/tree/main/gstack/investigate
Command: npx skills add https://github.com/LGJ-Jonathan/Jonathan_Global_Claude_Skills --skill investigate-lgj-jonathan

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Debugging often devolves into guessing and whack-a-mole fixes that treat symptoms instead of causes. This Skill enforces a disciplined five-phase debugging workflow that finds the actual root cause before any code changes, then proves the fix works with regression tests. ## Core Features & Use Cases - Root Cause Investigation: Traces symptoms through code paths, git history, and reproduction steps before forming any hypothesis. - Hypothesis Testing with Guardrails: Matches bugs against known patterns (race conditions, nil propagation, state corruption), applies a 3-strike escalation rule, and locks edit scope to the affected module. - Verified Fixes with Regression Tests: Requires a test that fails without the fix and passes with it, plus a structured debug report with evidence. - Use Case: A user reports "checkout fails intermittently in production." The Skill traces the error, checks recent commits to the payment module, identifies a race condition in session handling, confirms it with a targeted log statement, then ships a minimal fix with a regression test. ## Quick Start Ask the assistant to investigate why your application throws a specific error and find the root cause before fixing it.

Frequently Asked Questions about investigate

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

FAQPage Schema
How do I debug a bug systematically instead of guessing?

Follow a phased approach: collect symptoms and stack traces, trace the code path, check recent git changes, and reproduce the bug before forming a hypothesis. Only write a fix after the root cause is confirmed with evidence like a targeted log statement.

How to find the root cause of an intermittent bug?

Intermittent bugs often indicate race conditions or timing-dependent state issues. Gather reproduction evidence, check concurrent access to shared state, and add temporary logging at suspected points rather than applying speculative fixes.

What should I do when multiple fix attempts fail?

After three failed hypotheses, stop and escalate. Repeated failures usually signal an architectural problem rather than a simple bug. Options include continuing with a new hypothesis, escalating for human review, or adding instrumentation to catch the bug next time.

Why write a regression test for a bug fix?

A regression test proves the fix works and prevents the bug from returning. It must fail without the fix and pass with it, confirming both that the test is meaningful and that the root cause was actually addressed.

When should a bug fix be escalated instead of shipped?

Escalate when the root cause remains unclear after investigation, when the fix touches more than five files, or when you cannot reproduce and verify the fix. Unverifiable fixes create worse problems than the original bug.