DEV Community

Cover image for Your Codebase Was Always This Bad
Jono Herrington
Jono Herrington

Posted on • Originally published at jonoherrington.com

Your Codebase Was Always This Bad

A team turned on agent mode a month ago. First week, ecstatic. Shipping faster than they had in years. Second week, incidents started showing up. Third week, they were ready to blame the tool.

Then their senior pulled up the logs. Found the bug. Traced it back. The function had been broken since 2019. The AI just called it correctly for the first time in years.

The room went quiet.

They had shipped around that broken function for six and a half years. Workarounds in three services. Documented in runbooks. Never fixed because it never broke loud enough to matter. The fragility was always there. They had learned to dance around it so well they stopped seeing it.

The AI didn't create the problem. It walked into a house of cards and accidentally leaned on a wall.

The Pattern Keeps Showing Up

I was on a call last month with a team that's all in on AI. Slack full of celebration emojis. Pull requests flying. Shipping faster than ever. And their most senior engineers were terrified.

Monorepo with submodules. No specs, no Docker, no clean local setup. New developers take weeks to get running. The codebase is an atrocity that everyone had silently agreed to live with.

QA told me the engineers are throwing code over the wall now. Ship fast, fix later. Except later never comes. The defect queue keeps growing. A piece of work originally estimated at two weeks is still open six months later.

They don't blame the AI for breaking things. They blame themselves for what the AI revealed.

The whole org is chanting "ship faster, ship faster, ship faster." Celebrating motion while the foundation erodes. Activity dressed up as progress.

I Was the Genie User

I got this wrong myself when I first started.

I was building an app to bridge design and development. Take a Figma payload, convert it to production-ready code, eliminate the handoff. The promise was huge. Ship faster. Close the gap between design intent and working software.

I fell into vibe coding. I'd ping the model with what I wanted, then wait for magic. No structure. No guardrails. Just me wishing code into existence and the AI trying to comply.

The output looked right at first glance. But the design models were wrong. The code was verbose, layered with assumptions it couldn't have known to question. It wasn't solid. It was code built on foundations I had never explained, doing things I hadn't specified, making choices I hadn't authorized.

I was asking a junior engineer to read my mind and getting annoyed when they couldn't.

The breakthrough came when I stopped treating AI like a completion engine and started treating it like a new team member who needed context. Guardrails. Documentation that explained why the system worked the way it did. Clear boundaries around what the AI could assume and what it couldn't.

Once I did that work, the output changed. Not because the model got better. Because I had stopped wishing.

The Light Got Brighter

Race conditions that existed for years. Null references that always threw but never mattered. Configuration drift that a dozen services had quietly learned to tolerate.

The code didn't get worse when AI showed up. The light got brighter.

The teams winning right now aren't just shipping faster. They're going back and fixing foundations first. Adding specs. Documenting invariants. Creating boundaries the AI can understand and respect. They're doing the work that makes the AI useful instead of asking it to do magic on top of ruins.

AI accelerates whatever direction you're already heading. Solid foundation, you compound. Cracked foundation, you find the cracks sooner.

The codebase was always this bad. The AI just made it visible.

What assumption in your codebase has survived because nobody ever tested it?


One email a week from The Builder's Leader. The frameworks, the blind spots, and the conversations most leaders avoid. Subscribe for free.

Top comments (0)