RubyFlow The Ruby and Rails community linklog

Submit a post

You can use basic HTML markup (e.g. <a>) or Markdown.
Note that your post may be edited to suit the format of the site.

As you are not logged in, you will be
directed via GitHub to signup or sign in

Post Preview

Note: Only the first pargraph is shown on the front page and overly long paragraphs may be broken up.

Today

The Agents on Rails Files: designing black-box evals for coding agents

Agents on Rails is the Rails Foundation’s LLM benchmark. Evil Martians designed its evaluation tasks and the tooling to run trials at scale. On our blog, we’re going behind the scenes. First up: how we wrote black-box checks for apps whose code we’d never seen, to keep trials fair and results reliable. Bonus: the same evals run against Rust. Read more

Seven layers of cache in a Rails app, from the browser to Russian doll

This post walks through the seven places a request can be answered before it reaches Postgres: browser cache (expires_in, fresh_when), Varnish, Nginx proxy cache, action caching, Russian doll fragments in ERB and jbuilder, Rails.cache on Memcached or Solid Cache, and an object cache on Redis. Each layer comes with its config, what it actually saves, and how it breaks (cookies vs Varnish, CSRF in cached actions, sharing Redis with Sidekiq). Ends with a suggested build order: headers first, edge last. Read more

API Versioning in Rails: Start at /api/v1 Before You Think You Need It

Most Rails APIs start as a format.json branch in an HTML controller and only become an API once a partner depends on them. This post lays out the structure to put in place before that: URL path versioning starting at /api/v1, an Api::BaseController < ActionController::API that owns auth, error envelopes and transaction tagging, and one thin base per version. Read more

parallel_matrix_formatter: one readable display for parallel RSpec runs

Running specs with parallel_tests or parallel_split_test gives you interleaved output from every process and a separate failure report per process. parallel_matrix_formatter is an RSpec formatter that sends results from all processes over a UNIX socket to process 1, which renders a single progress display and one consolidated failure report with rerun commands. It also silences stray stdout, keeps each process’s stderr in a log, and the progress display looks like Matrix digital rain. Version 0.2.0 is out: gem install parallel_matrix_formatter. Feedback from real suites is very welcome.

Foreman or Docker Compose? The ideal local Rails setup in 2026

Native Procfile.dev or everything in docker-compose? This post argues for a hybrid: run web, css, js and workers natively via bin/dev, and keep only Postgres and Redis in a minimal compose file pinned to production versions. It covers why bind mounts slow Rails down on macOS, the Postgres 18 volume path change, OrbStack vs Docker Desktop memory usage, when a devcontainer still wins, and dropping Redis in dev with Solid Queue.

A new version of bidi2pdf is out

The highlight of this release is built-in support for Claude Code skills. The repository now includes a Claude Code plugin with skills that help AI agents generate PDFs, troubleshoot rendering issues, and work with Chrome through WebDriver BiDi. Read more

ruby_llm-providers-lms v0.3.0 with decisions API released

ruby_llm-providers-lms 0.3.0 brings RubyLLM 2.1’s judgments to LM Studio. Point RubyLLM.judge or a RubyLLM::Judge class at a local decision model and get typed answers back in tens of milliseconds: a probability that something is true, a choice from a fixed set with a confidence, or a score on an ordered scale, with no text to parse and nothing generated. Read more

llm.rb v17.0.0 released!

llm.rb is an agentic runtime for building AI applications on CRuby. It supports 14 different providers, it has zero runtime dependencies by default, and it can execute tool calls on their own process, thread, Async::Reactor, or Ractor. It can reliably interrupt an agent running in the same process but a different thread or fiber, too. Plus much more. Check it out if that sounds like your thing :)

Upgrading a Rails app from Ruby 3.4.4 to 4.0.3: what actually breaks

Ruby 4.0 is the first major bump in over a decade, but a Rails 8.x app usually upgrades in a day of focused work. Most of the pain is not in the language: it is gems that left the default set (cgi, ostruct, logger, benchmark), the Ractor::Port rewrite, Kernel#open("| cmd") no longer spawning a process, and a handful of changes that break tests rather than code (Set#inspect output, Net::HTTP no longer defaulting Content-Type on bodies, new backtrace frames that confuse Sentry/Datadog grouping rules). Read more

Gravity Defied, the old fashion motorbike game, rebuilt with pure Ruby physics

Remember Gravity Defied, the motorbike game from old Nokia phones? I rebuilt it on DragonRuby GTK with the physics written in pure Ruby: no physics engine, just six point masses joined by springs and 16.16 fixed-point math. Thanks to WebAssembly, you can play it right in the browser with all 30 original tracks. Since every run is deterministic, a small beam-search bot finds clean runs offline, and the game replays them frame for frame

SolidJobs + SolidTrace + Warm IPC perform worker 2000 alloc/s vs 200 alloc/s sidekiq

We are told that to scale Ruby background workloads across multiple CPU cores, we have two choices: process forking (e.g., Pitchfork) which incurs massive Copy-on-Write memory overhead and risk of OOM kills under load, or database-backed queues (e.g., Solid Queue) which introduce heavy synchronous disk I/O and row-locking bottlenecks [1.8, 1.10]. To break this cycle, I built SolidJobs (v0.5.0): an open-source, Ractor-local Redis task runtime engineered from scratch around a strict shared-nothing architecture [1.8]. Read more

Rails engines: a gem that lives inside your app

How to build a feature as a Rails engine in a folder of the main app, loaded as a path gem. Covers isolate_namespace, appending the engine’s migrations to the host instead of copying them, a single lambda hook for auth so the engine never depends on the host, and where engines hurt (specs, Zeitwerk, schema visibility). Real code from a short-link and click-tracking feature. Read more

Loading older posts