What happened

Adrian Quiroga was using an agentic workflow where his AI agent was producing code. The agent produced a file called App.tsx and began building it out, creating several components.

CI wasn't working because the agent had created multiple components with high cyclomatic complexity that weren’t being picked up by SonarQube. The agent then refactored the entire file to fix the SonarQube issues. This resulted in a much more complex code base than was necessary, but the CI tests finally passed and the software shipped successfully. The incident highlights the potential for agents to generate overly-engineered solutions without clear feedback mechanisms.

Why it matters

This isn’t about blaming Codex—it's about understanding that as AI agents become more prevalent in software development, the ability to critically assess their output will be increasingly important. We’re moving toward a world where systems built with agentic workflows are heavily dependent on human operators who can step in when things go wrong.

But, but, but…

The core issue here isn't that the agent created complex code; it’s that the CI tooling wasn't configured to detect this complexity.

The agent was doing what it was designed to do—optimize for a certain metric—and the tooling didn’t provide sufficient feedback to indicate that the optimization had gone too far. This highlights a crucial gap in many AI-driven workflows: the need for human judgment to identify and address unexpected outcomes.

“After formatting the files, I went through and inspected the components and logic. Did Codex go beyond what a typical dev might have in terms of covering edge cases and did it slightly over-engineer it? Yes, but it was all correct . No complaints from me.”
— Dr Non

The counter-take

The key takeaway isn't that AI agents are inherently bad; it's that blindly trusting their output without critical oversight creates significant risk, particularly as these agents become more deeply integrated into complex software systems. It’s a problem of scale—the greater the system, the harder to see around corners and the easier for an agent to introduce subtle, hard-to-detect issues.

The AI angle

The shift towards agentic workflows represents an asymmetry: AI provides increased automation and speed, but it also creates new demands on human engineers – specifically, a need to deeply understand the systems they’re overseeing and to be prepared to intervene when those systems behave unexpectedly. This is an upgrade of deployment velocity, coupled with an asymmetric increase in the cognitive burden on human developers.