clj-debug
Installation
SKILL.md
Why REPL-based Debugging for Clojure
Adding logs and re-running tests creates a slow feedback loop. Clojure's REPL lets you inspect values directly at the point of failure, test fixes instantly, and validate corrections before touching the source file. This is faster and safer than println or formal debuggers.
Core Pattern: Stop Before Logging
RED FLAG: You're about to add println, tap>, (log ...), or modify source code to debug.
Instead: Use inline def in nrepl. Evaluate modified code directly without changing files, capture values, inspect them, test your fix, then commit with confidence.
The Inline Def Pattern: Capture and Inspect
When a function fails, add a temporary (def variable-name variable-name) inside the function and evaluate the modified function in nrepl. This captures the value without changing the source file.
Example: Discovering a Calling Convention Bug
Your function fails: