brokeinprod
field notes from production// 31.0°N

Ship it. Then write down what broke.

The error message, the actual cause, and the one-line fix — from really building apps on Next.js, Postgres, Vercel, Rust, and Python. No fluff, no listicles, just the gotchas that cost an afternoon.

image-pipeline.ts
const output = await sharp(input)
  .rotate()                    // auto-orient BEFORE exif is stripped
  .resize({ width: 1600 })
  .webp({ quality: 82 })
  .toBuffer();                 // exif + gps gone by default
What's here

Topics, written from the build — not the docs.

Latest

Recent entries.

Built for reading code

Code you can actually read at 1am.

Every snippet is real, copy-ready, and rendered with the line that matters lit up — because that's the line you came for.

  • Syntax highlighting tuned for a dark room.
  • One-tap copy on every block.
  • The fix line highlighted, not buried.
proxy.ts (was middleware.ts)
export function proxy(request: NextRequest) {
  const isLive = process.env.SITE_LIVE === "true";
  const { pathname } = request.nextUrl;
  if (!isLive && !exempt(pathname)) {
    return NextResponse.rewrite(new URL("/soon", request.url));
  }
  return NextResponse.next();
}

Newsletter

New posts in your inbox. No spam — unsubscribe anytime.

Occasional emails when we publish something worth your time. Unsubscribe anytime.

More about what you'll get on the newsletter page.

THEME