This Week in Rails

July 12, 2024

New Rails beta release, immutable option in http_cache_forever and more

Hi, Wojtek here again. See another short list of changes from this past week.

Rails 7.2.0.beta3 have been released
With 91 commits since the last beta 2 version.

Make http_cache_forever use immutable option
The immutable: true option was added to expires_in in last week. This change sets immutable: true option for http_cache_forever which additionally affects proxied Active Storage files.

Do not watch for translation changes from gems
Optimizes the load time for I18n initialization by restricting I18n load paths passed to the file watcher to only those within the applications directory. Previously, the watcher would grab all of the available locales, including those in gems which do not require a watcher because they don’t change.

Fix duplicate callback execution when child autosaves parent association
Before, persisting a new child record with a new associated parent record would run validation and save callbacks twice. Now, these callbacks are only executed once as expected.

You can view the whole list of changes here. We had 19 contributors to the Rails codebase this past week!

Until next time!

About This Week in Rails

Your weekly inside scoop of interesting commits, pull requests and more from Rails.