How to Upstream Your Code to Rails
summary
A concrete how-to: shows a real upstream of an immutable validator -> read-only validator, adds tests, updates the changelog, and runs a Benchmark.ips script with an inline Gemfile that finds a 6x faster implementation; opens PRs, iterates on review, fixes a regression found in a monolith (abstract‑class setter edge case), and finally gets the change merged so the app can delete its custom validator and rely on Rails in the next major release.
AI-written summary · about
chapters (13)
- 0:00Contributing to Rails
- 1:07Why contribute code
- 3:55Open source citizen
- 5:18What to upstream
- 7:26Finding Rails bugs
- 8:49Performance improvements
- 10:34New Rails features
- 10:54Case study: validator
- 14:45Writing a pull request
- 17:54Handling PR feedback
- 21:27Waiting for reviews
- 22:30Fixing regressions
- 25:42Summary and next steps
related talks
31mOff the Rails: Validating non-model classes with…ActiveModel?
26mContributing to Rails? Start with the Gems You Already Use
39mDown The Rabbit Hole: An Adventure in Legacy Code
24mValidate Me! - Demystifying Rails Validators
29mUpgrading Rails at Scale
26mDon't Rewrite Your Framework
33mSo You Want to Start Refactoring?
41mTerraforming legacy Rails applications
