Fetching from the wire…
Public story · 2026-07-20 · high
Bun's Zig-to-Rust port spent 5.9 billion input tokens and 165,000 dollars, and passed the full existing test suite before merge.
Why now: Anthropic published the cost breakdown as part of the migration writeup entering coverage on July 20, 2026.
Anthropic put real numbers on what an agentic migration costs. Engineering teams sizing up a large agent-run rewrite now have a real budget line to compare against. The failure rate is real too: 19 regressions surfaced after a 1,448-file migration merged, per Anthropic's engineering post.
Bun's Zig-to-Rust port ran through Claude Code and produced a million lines of code in under two weeks. The result landed as a single pull request spanning 1,448 files, the company says.
100% of the existing test suite passed before that PR merged, per Anthropic.
The token bill was 5.9 billion uncached input tokens and 690 million output tokens, about $165,000 at API pricing, by Anthropic's count.
Nineteen regressions surfaced after the merge, not before, the company says. All of them got fixed.
The payoff: 19% smaller binaries, 2 to 5% better throughput, and one benchmark that dropped from 6,745 MB to 609 MB, per Anthropic's post.
A test suite passing before merge and a codebase clean of regressions after merge are different claims. Anthropic's numbers show the gap between them.
A separate migration moved 165,000 lines of Python to TypeScript over a single weekend, Anthropic says. Hundreds of agents did the work behind eight phase gates and three rounds of adversarial review, per the same post.
That migration cost 27 million tokens, per Anthropic, a fraction of the Bun job's spend since the code volume was smaller.
If you're running a migration with agents, budget for the review pass as its own line item, not an afterthought. Anthropic's own numbers say the model didn't catch everything on the first pass, and yours won't either.
Each link below shares sources, entities, or timing with this story.
Same source
Cite the same source (Anthropic / Hacker News).
Cite the same source (Anthropic / Hacker News).
Same source domain / Semantically similar
Reported by the same outlet (claude.com); covers closely related ground (similarity 0.66).
Semantically similar
Covers closely related ground (similarity 0.75).
Covers closely related ground (similarity 0.75).
Same source domain
Reported by the same outlet (claude.com).
Reported by the same outlet (claude.com).
Reported by the same outlet (claude.com).