
How I Built a Self-Healing Node.js System That Fixes Production Bugs While I Sleep
So I had this problem. I run a couple of Node.js services and every few days something would break in production — a bad query, a null reference, some edge case nobody thought of. I'd find out from logs way too late, ssh in, figure out what happened, write a fix, test it, push it. Every. Time. At some point I thought — what if the system could just... fix itself? Or at least get 90% of the way there and ask me to approve? Thats how LevAutoFix was born. Its an automated error detection and remediation system that watches production logs, classifies errors by severity, launches Claude Code in headless mode to generate fixes, and sends me a Telegram message to approve or skip. One tap from my phone, PR gets created. Heres how the whole thing works. The Architecture — Two Processes The system is split into two separate processes: Watcher — runs on the production server. Its only job is watching log files, detecting errors, and relaying them. Fixer — runs on my dev machine. Receives classif
Continue reading on Dev.to
Opens in a new tab



