Skip to content
cccskills
FreePublished on GitHub

ls-debug-reproducible-failures

Use when debugging reproducible failures with a systematic method and language-specific commands for Node, Python, Swift, CSS/layout, network, or git bisect.

The English summary is being prepared. Showing the original description.

See how to install

Files included (1)

  • SKILL.md4.2 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

Debug Pro

Systematic debugging methodology and language-specific debugging commands for application code, CSS/layout, network issues, and git bisect workflows.

Source note: imported from debug-pro by cmanfre7; provenance was previously recorded in release-only _meta.json metadata with upstream version 1.0.0.

The 7-Step Debugging Protocol

  1. Reproduce - Get it to fail consistently. Document exact steps, inputs, and environment.
  2. Isolate - Narrow scope. Comment out code, use binary search, check recent commits with git bisect.
  3. Hypothesize - Form a specific, testable theory about the root cause.
  4. Instrument - Add targeted logging, breakpoints, or assertions.
  5. Verify - Confirm root cause. If hypothesis was wrong, return to step 3.
  6. Fix - Apply the minimal correct fix. Resist the urge to refactor while debugging.
  7. Regression Test - Write a test that catches this bug. Verify it passes.

Language-Specific Debugging

JavaScript / TypeScript

# Node.js debugger
node --inspect-brk app.js
# Chrome DevTools: chrome://inspect

# Console debugging
console.log(JSON.stringify(obj, null, 2))
console.trace('Call stack here')
console.time('perf'); /* code */ console.timeEnd('perf')

# Memory leaks
node --expose-gc --max-old-space-size=4096 app.js

Python

# Built-in debugger
python -m pdb script.py

# Breakpoint in code
breakpoint()  # Python 3.7+

# Verbose tracing
python -X tracemalloc script.py

# Profile
python -m cProfile -s cumulative script.py

Swift

# LLDB debugging
lldb ./MyApp
(lldb) breakpoint set --name main
(lldb) run
(lldb) po myVariable

# Xcode: Product -> Profile (Instruments)

CSS / Layout

/* Outline all elements */
* { outline: 1px solid red !important; }

/* Debug specific element */
.debug { background: rgba(255,0,0,0.1) !important; }

Network

# HTTP debugging
curl -v https://api.example.com/endpoint
curl --silent --show-error --output /dev/null \
  --write-out 'status=%{http_code} dns=%{time_namelookup}s connect=%{time_connect}s tls=%{time_appconnect}s first_byte=%{time_starttransfer}s total=%{time_total}s\n' \
  https://example.com

# DNS
dig example.com
nslookup example.com

# Ports
lsof -i :3000
netstat -tlnp

Git Bisect

git bisect start
git bisect bad              # Current commit is broken
git bisect good abc1234     # Known good commit
# Git checks out middle commit - test it, then:
git bisect good  # or  git bisect bad
# Repeat until root cause commit is found
git bisect reset

Common Error Patterns

ErrorLikely CauseFix
Cannot read property of undefinedMissing null check or wrong data shapeAdd optional chaining (?.) or validate data
ENOENTFile/directory doesn't existCheck path, create directory, use existsSync
CORS errorBackend missing CORS headersAdd CORS middleware with correct origins
Module not foundMissing dependency or wrong import pathnpm install, check tsconfig paths
Hydration mismatch (React)Server/client render different HTMLEnsure consistent rendering, use useEffect for client-only
Segmentation faultMemory corruption, null pointerCheck array bounds, pointer validity
Connection refusedService not running on expected portCheck if service is up, verify port/host
Permission deniedFile/network permission issueCheck chmod, firewall, sudo

Quick Diagnostic Commands

# What's using this port?
lsof -i :PORT

# What's this process doing?
ps aux | grep PROCESS

# Watch file changes
fswatch -r ./src

# Disk space
df -h

# System resource usage
top -l 1 | head -10

2026-07 Refresh Note

Compared against upstream debugging workflow sources during the skill import wave. Keep the LocalSetup seven-step protocol as the stronger default: reproduce, isolate, hypothesize, instrument, verify, fix, and add a regression test.

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

Guide accessibility reviews for UI, documents, and workflows. Use for WCAG-oriented audits, keyboard review, semantics, contrast, and remediation planning.

The English summary is being prepared. Showing the original description.

CruxExperts/LocalSetup6Updated Oct 21, 2026

Use when choosing a LocalSetup Agent-* lane for exploration, research, bounded implementation, or review. Consult the static capability matrix; do not probe account or network availability.

The English summary is being prepared. Showing the original description.

CruxExperts/LocalSetup6Updated Oct 21, 2026

Guide agent email inbox workflows with prompt-injection defenses. Use for inbound email processing, webhooks, routing, and safety review.

The English summary is being prepared. Showing the original description.

CruxExperts/LocalSetup6Updated Oct 21, 2026

Navigate and understand codebases using agentlens hierarchical documentation. Use when exploring new projects, finding modules, locating symbols in large files, finding TODOs/warnings, or understanding code structure.

The English summary is being prepared. Showing the original description.

CruxExperts/LocalSetup6Updated Oct 21, 2026

Use for Agent Q signed encrypted file-drop or mail ship and ingest, private registry v2 setup, queue status, and transport maintenance.

The English summary is being prepared. Showing the original description.

CruxExperts/LocalSetup6Updated Oct 21, 2026

Inventory wrapper for the alirezarezvani Claude skills bundle. Use when triaging its broad skill catalog and large script surface before any targeted import.

The English summary is being prepared. Showing the original description.

CruxExperts/LocalSetup6Updated Oct 21, 2026

See all skills by CruxExperts

Report a problem with this skill