Skip to Content
Code as Data
book

Code as Data

by Bryan Friedman, Pat Johnson, Olga Kundzich
July 2026
Intermediate
35 pages
52m
English
O'Reilly Media, Inc.
Content preview from Code as Data

Chapter 5. Code Quality, Testing, and Dependencies

Coding agents produce and change code faster than anyone can review it. They’ll confidently modify a method with a cyclomatic complexity of 47, zero test coverage, and 200 call sites depending on it, where a careful engineer would just leave it alone. And an agent not only runs into code like this, but it also generates it. The same data on quality that steers an agent away from risky code catches the risky code it just wrote.

Quality dashboards, coverage reports, and dependency scans all live on a server for a human to review. To an agent that opens a repo and acts in seconds, information that isn’t clearly accessible is, functionally, information that doesn’t exist (or must be inferred). This chapter is about three categories of codebase knowledge—quality, tests, and dependencies—and why agents and humans both need them as real-time data, resolved from the code itself and current at the moment of the next change.

Code Quality as Continuous Signal

Code quality used to be a question of whether the code was readable, testable, and understandable by the next engineer. That still holds. But agents add a more urgent question: What is the health of the codebase at the moment the next change starts? A 78% maintainability score on a dashboard doesn’t help an agent that just opened a 2000-line class.

Complete quality data needs to answer questions at three altitudes, because problems at one level are usually symptoms at another:

Method ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

RAG-Ready Patterns for Data Platforms

RAG-Ready Patterns for Data Platforms

Ravi Vedula, Gerardo Bodegas Martinez, Maruti Chittajallu, Jack Pullikottil
Implementing Data Mesh

Implementing Data Mesh

Jean-Georges Perrin, Eric Broda
Data Mesh

Data Mesh

Zhamak Dehghani

Publisher Resources

ISBN: 0642572333225