AI coding agents now open 40% of pull requests on GitHub, and they don’t respect the unwritten “keep it small” rule. GitHub’s answer: rebuild the diff renderer in the Copilot app from scratch so a million-line PR doesn’t turn code review into a waiting exercise.
Principal Design Engineer Alberto Gimeno published the technical post on November 16. The rebuilt diff surface in the Copilot app can handle a pull request with 2,200 files, over a million changed lines, and 400 inline review comments — and it opens like a normal PR.
What Broke, and Why
The old renderer had two compounding problems. Every diff line mounted roughly eight React components and ten DOM elements. That’s manageable for a 50-file PR. For 2,200 files, it meant millions of DOM nodes before the first scroll.
The comment problem was worse. The old approach used one ResizeObserver per comment block, each one writing its measured height back into the layout. That creates a feedback loop: the observer writes a height, which triggers a reflow, which triggers the observer again. The cost compounds with every visible comment.
The Two-Domain Fix
The core insight is that a pull request contains two fundamentally different kinds of content. Code diff rows have a known, fixed height at a given font size. Comment blocks don’t — their height depends on markdown wrapping, reply composers, expandable sections, and images still loading.
The rebuild handles them separately. Code rows get computed once and cached. Comment blocks get measured by a single idle- and scroll-gated pass that reads all mounted blocks in one batch, instead of letting individual observers fight each other. The observers still exist, but they only flag a block for re-reading; they never write heights directly.
The DOM footprint per diff line is cut roughly in half. So is the React component count. The result is a surface that scrolls through a million lines without jank.
Why GitHub Built This Now
The numbers make the case. GitHub’s Octoverse 2026 report shows agent-started pull requests went from 17% of all PRs in March to over 40% by September — 110 million agent-drafted PRs in that month alone. And agents don’t write small PRs: 87% of agent-started PRs change more than one file, compared to 79% for human-authored ones.
Meanwhile, a Harvard study covering over 700,000 engineers at 700+ firms found that AI agents increase per-worker lines of code by 30%, commits by 20%, and pull requests by 23%. But a 49% longer review cycle cancels the productivity gain at the firm level. The share of workers assigned to code review rose 14%.
The bottleneck moved. For decades, writing code was the scarce resource. With AI agents, writing is essentially free — the constraint is now reading, verifying, and approving what agents produce. GitHub’s diff rebuild is the most direct response to that shift yet from a major platform.
What This Means in Practice
Until now, teams dealing with oversized agent PRs had two bad options: break the PR into smaller chunks manually (tedious, defeats the purpose of running an agent) or use terminal-based diffing tools with less context. Some teams simply relied on automated checks and skipped visual review entirely.
The Copilot app fix doesn’t require any workflow changes. The same PR that previously locked up the diff view now opens cleanly. For teams already running agents at scale, this removes a real daily friction point.
One caveat worth noting: this fix is specific to the GitHub Copilot app. The standard GitHub.com web diff view is a separate codebase and hasn’t received the same treatment yet. If you’re reviewing agent-generated PRs regularly, this is an argument for making the Copilot app your primary review interface.
The Bigger Picture
GitHub isn’t alone in rethinking version control for the agent era. OpenAI, Meta, and others are working on Git tooling designed for agent commit cadence, which is orders of magnitude higher than human cadence. The diff rebuild is one piece of a larger infrastructure shift happening across the industry.
The practical takeaway: software development has changed, and the tools are finally starting to catch up. If your team runs AI coding agents, your bottleneck is code review, not code generation. InfoQ’s coverage has further technical context if you want to go deeper on the implementation.

