Best of BunMay 2026

  1. 1
    Article
    Avatar of collectionsCollections·15w

    Bun is being rewritten in Rust, moving away from Zig

    Bun's creator Jarred Sumner used Claude as a coding agent to port over one million lines of Zig code to Rust in roughly six days, shipping the result as a near-complete rewrite. The port passed 99.8% of Bun's test suite, reduced binary size, and matched or slightly exceeded performance benchmarks. The motivations were Zig's persistent memory bugs, its pre-1.0 instability, and a no-AI contribution policy that conflicted with Anthropic's (which acquired Bun's parent company) working style. However, the rewrite contains ~10,000 unsafe blocks, is non-idiomatic Rust, and critically, no human has fully reviewed the codebase — it was written and reviewed by Claude. Several security bug reports have already appeared, yt-dlp deprecated Bun support above 1.3.14 citing reliability concerns, and Electrobun announced it's decoupling from Bun. The episode raises unresolved questions about AI-generated codebases: test suites validate known paths but can't catch subtle invariants or concurrency bugs, and the gap between generating a million lines of code in six days versus understanding what it does remains a fundamental challenge.

  2. 2
    Article
    Avatar of collectionsCollections·15w

    Bun v1.3.14: built-in image processing, global virtual store, HTTP/3, and more

    Bun v1.3.14 ships with a native image processing API (Bun.Image) that claims to outperform sharp, ~7x faster warm installs via a global virtual store, experimental HTTP/2 and HTTP/3 client support in fetch(), and HTTP/3 (QUIC) server support in Bun.serve(). The fs.watch() backend has been fully rewritten for Linux, macOS, and FreeBSD. Additional highlights include ~12% faster ESM module loading, a JavaScriptCore engine upgrade with 565 upstream commits, cross-language LTO reducing Windows binary size by up to 18 MB, Bun.Terminal on Windows via ConPTY, FreeBSD and Android builds, and 92 bug fixes including Node.js compatibility and memory leak improvements.

  3. 3
    Article
    Avatar of atul3chxfypngktbogislRene Yibowei·13w

    Bun’s 1M-line AI Rust rewrite has 13,365 unsafe blocks—and it made me glad I chose to learn Deno

    A student developer shares their reaction to Bun's AI-assisted rewrite of its codebase from Zig to Rust — a nearly 1-million-line port executed by Claude agents in six days. The rewrite introduced 13,365 unsafe blocks, giving Bun an unsafe density of 13.7 per 1,000 lines, nearly double Deno's 8.4. Five functions with real undefined behavior were flagged in the pre-release audit. The author argues the deeper problem is that no human fully understands the new codebase, raising concerns about hidden bugs, security vulnerabilities in a privileged runtime environment, and compounding technical debt. They conclude that Deno's hand-crafted, human-audited Rust codebase is the safer choice for backend development.

  4. 4
    Article
    Avatar of rust_digestRust Digest·14w

    Bun rewrites in Rust, unsafe call count tells the real story

    Bun's codebase was rewritten from Zig to Rust in under a week — 960,000 lines ported almost entirely by Claude Code — with Bun 1.3.14 marking the last Zig release. The rewrite passes tests and slightly improves performance, but raises concerns with 13,000+ unsafe calls versus uv's 73, making it closer to C++ with a Rust compiler than idiomatic Rust. Cloudflare's quiche team published a post-mortem on a QUIC CUBIC congestion bug caused by a misported Linux kernel idle-detection heuristic, fixed with a one-line change. Other highlights include oxlint cutting config discovery time in half via readdir-based traversal, a 5.9x speedup in image-rs's fast_blur using integer accumulators and reciprocal multiplication, and a roundup of Rust ecosystem news including rust-analyzer releases, Cloud Hypervisor 52, IBM s390 Rust kernel support, and more.