Submit a post
Post Preview
Note: Only the first pargraph is shown on the front page and overly long paragraphs may be broken up.
Today
What Should Go in AGENTS.md for a Rails App?
After working with agents and agent files for tons of apps, repos, projects, I decided to distill my thoughts on it: Read more
rails-preflight: what stands between your Rails app and the next version
I just released a gem that answers one question about a Rails app: what stands between it and Rails X? Read more
Callbacks, Concerns, and Current: Avoiding Hidden Dependencies in Rails
Callbacks, concerns, and Current keep code close to the model, but can hide effects and dependencies. When to use them and how to make those dependencies explicit. Read more
Fixing SPA Link Previews with a Lambda in Front of AWS Amplify (and Why Rails Never H
Link preview crawlers don’t run JavaScript, so every route of a static SPA shares the same generic card. In Rails, a content_for :head block solves this per request. Without a server in the request path, you have to put one back. Read more
Rails 8 with Inertia and React: Hotwire Alternative Guide
Building a Rails 8 admin panel with Inertia and React instead of Hotwire: the trade-offs, the architecture, and a practical tutorial.
Shrinking a 130 GB Postgres to a Local Copy with Greenmask: What Worked and What Brok
Staging had grown past 130 GB, a full pg_dump was out of the question, seeds never reproduced real bugs, and the data was full of PII. This post walks through building a small, FK-consistent, masked subset of a Rails app’s Postgres with Greenmask. It covers virtual references for Rails associations that never got a database FK, and masking every user to user<ID>@example.test with a known dev password. It also goes through the six things that broke and how each was fixed: NULL-owner rows slipping through, a self-referencing FK that panics the planner, invalid SQL from polymorphic references, orphan rows, the source running out of temp space on a 70 GB table, and a PostGIS NOTICE that aborts the restore. The result is a repeatable pipeline: restore by section, run a repair pass before the FKs are created, then verify.
Hot Cell for Active Storage
This summer, Mike handled CVE-2026-66066, an Active Storage vulnerability that let a crafted image upload read files from the server, including your application’s secrets. Read more
Don't bet on SELECT's order: shuffle your rows and see what folds
SELECT * FROM posts carries no promise about the order of the returned posts. Yet, every relational database hands them back in some order, and code and tests start depending on that order. You can’t grep for a bug like this, but you can smoke it out by deliberately shuffling the rows of every unordered query and seeing what fails. (Rails has since merged a switch of its own from Evil Martians, config.active_record.shuffle_unordered_selects, due in 8.2.) We also share pg_disorder, the open-source PostgreSQL extension we built to do the same thing at the database level. Read more
Brunch Gem: Isolated Development Environments for Git Branches and Worktrees
Brunch is a Ruby gem that gives Git branches and worktrees isolated development environments. Each branch can have its own containers, network, volumes, and persistent state, while each worktree gets its own host port. This makes it easier to switch between branches safely and to run multiple worktrees in parallel, including workflows driven by IDEs and coding agents. Read more
What retry_on Actually Means
A Rails job sends a webhook, then fails while saving its receipt. Trace what retry_on repeats, how attempts are counted, and how a failed retry enqueue behaves in Active Job 8.1.3, with a runnable reproduction and explicit Solid Queue differences. Read more
Rails World '26: The As-If Rule, Ractors & AI
I was in the audience at Rails World 2026 when Aaron Patterson (tenderlove) kicked off the closing keynote. Aaron opened with a well-worn line: “the purpose of a system is what it does.” He wasn’t satisfied with it. The purpose of a system, he argued, is what it does for whoever is observing it. Read more
The Future of Rails
A special edition of The Ruby AI Newsletter breaks down the Future of Rails now that AI can write most of the code, and all of the incredible developments since Rails World.
Testing JSON APIs in Rails
Chapter 16 of the free Minitest Rails guide is out now. Learn how to build a versioned API at /api/v1 and test full API: Read more
I Ran a Security Scanner Against Mastodon, Discourse, and Chatwoot's AWS Defaults. He
I used Stave, an open-source configuration safety tool, to answer those questions for three of the most popular open-source Rails applications: Mastodon (47K stars), Discourse (43K stars), and Chatwoot (22K stars). Read more
Building a Ractor-Native Ruby 4 Stack: RESP, Redis and Background Jobs
Building a Ractor-Native Ruby 4 Stack: RESP, Redis and Background Jobs Read more
Billing in Rails 8 — a practical guide to Pay + Stripe
I just released Billing in Rails 8, a 126-page implementation guide for building subscription billing into a Rails app with Pay and Stripe. It focuses less on getting the first Stripe Checkout session working and more on everything that comes after: keeping provider state separate from product behavior, stable application-level plans, entitlements and limits, trials, upgrades and downgrades, cancellation, failed payments, reconciliation, and testing the whole thing without making Stripe your application architecture. Read more
Tech Repost 2026-09-29: Programming Is Building a Mental Model
This applies to programming with any languages, including Ruby: Tech Repost 2026-09-29: Programming Is Building a Mental Model…
Rails World '26: The RubyGems Compact Index
Every time Bundler resolves your Gemfile, it’s talking to the compact index. In this post, the speaker walked us through what the compact index actually is, how RubyGems.org keeps it in sync at scale, and two features Jenny helped ship in the past year to make gem installs faster and more secure. Read more
Ruby Memes 2026-09-30: DHH's AI Vision
Ruby Memes 2026-09-30: DHH’s AI Vision
Rails World '26: Herb and ReActionView
ReActionView adds real reactivity to your existing .html.erb templates, no Hotwire, no Stimulus, no JavaScript you have to write yourself. That is the part that got me. Read more
Montreal.rb September 2026: Ruby Version Managers in 2026
The video and slides for the Montreal.rb September 2026 talk “Ruby Version Managers in 2026” have been published!