[ANN] Rails 4.2.7.rc1 and 4.1.16.rc1 have been released!

Hi everyone,

I am happy to announce that Rails 4.2.7.rc1 and 4.1.16.rc1 have been released.

As Rails 5 was released, this is probably going to be the last release of Rails 4.1. Please take some time to upgrade your application to Rails 4.2 or Rails 5.

If no regressions are found expect the final release this Thursday, on July 7, 2016. If you find one, please open an issue on GitHub and mention me (@rafaelfranca) on it, so that we can fix it before the final release.

CHANGES since 4.1.15

To view the changes for each gem, please read the changelogs on GitHub:

Full listing

To see the full list of changes, check out all the commits on GitHub.

CHANGES since 4.2.6

To view the changes for each gem, please read the changelogs on GitHub:

Full listing

To see the full list of changes, check out all the commits on GitHub.


If you’d like to verify that your gem is the same as the one I’ve uploaded, please use these SHA-1 hashes.

Here are the checksums for 4.1.16.rc1:

$ shasum *4.1.16.rc1.gem*
8e0be05cfb4e4516c75cc12c971fe4924f111762  actionmailer-4.1.16.rc1.gem
1ad0c0c1bc13ddf9f85c6b1d5cd6288d8d0114d6  actionpack-4.1.16.rc1.gem
ee83721f8f7a95b23aa93163fe3e01ba89ca046a  actionview-4.1.16.rc1.gem
35fa99af4f158079a444cb8473a0a3dd0465220b  activemodel-4.1.16.rc1.gem
680a69dc13474894c84054a1f2a9d23868d6000e  activerecord-4.1.16.rc1.gem
a03b6a27496cf08e215db8e487f3a06a45b0e29a  activesupport-4.1.16.rc1.gem
70bf01fb349592a8473d3ffedb873c9f9abc293d  rails-4.1.16.rc1.gem
5c6cc7659065da6f61fc3ff0bcc13439a4df8ee2  railties-4.1.16.rc1.gem

Here are the checksums for 4.2.7.rc1:

$ shasum *4.2.7.rc1.gem*
6deda04a33d767f0d9d7be5a199c98c359701b34  actionmailer-4.2.7.rc1.gem
723e016bcf59cb860b6343a4936f417c927dab09  actionpack-4.2.7.rc1.gem
19cef0c8418c294ebc46547e29d460c554a4d77c  actionview-4.2.7.rc1.gem
f1038a46fdcbd888dca12285d7bf8db2ea40f80c  activejob-4.2.7.rc1.gem
c48f4b32f0da8ea64541e8ca80b4e15a47e01ad1  activemodel-4.2.7.rc1.gem
0ef45fd5da001370593558cb8b64f5aba6d7de16  activerecord-4.2.7.rc1.gem
5969a35bf853ce9f872f6c99f4d75572d436a4ed  activesupport-4.2.7.rc1.gem
ac23853084ac321ce40a0e79d2f878ad18dac7a3  rails-4.2.7.rc1.gem
e9dde94765e7a8682ff4675f8ae47244a996644d  railties-4.2.7.rc1.gem

I’d like to thank you all, every contributor who helped with this release.

This Week In Rails: Rails 5 is out with new guides and more!

Hello open sourcerer!

Here’s Kasper rushing straight from the bullpen to the printers to report: Slow week, but we’ll get through it.

Just kidding! Rails 5 is here.

In fact, to really underline the magnitude of this achievement please play this music while you read.

Rails 5 is here!

After a period of betas Rails 5.0 has now been released. The headline features are Action Cable and a mode primed for API-only apps.

There are also loads of other goodies which we’re covered here before. Check out our archives or comb through the 9999 commits themselves.

Guides updated for Rails 5

If you’d like a more high level overview there’s also new guides ready.

You can find tips on upgrading, there’s a new version of the testing guide — and there are the full release notes, which has a lot of details.

Rails 5: made by you and me

Rails 5 wouldn’t be possible without the 948 people who put in free time to help make these releases happen. A roaring thank you goes out to every contributor big and small. ❤️

(Here’s what happened just this week.)

Wrapping Up

That’s it from This Week in Rails! There were many other great contributions, too numerous to list here, but feel free to check them out!

Until next week!

Rails 5.0: Action Cable, API mode, and so much more

After six months of polish, four betas, and two release candidates, Rails 5.0 is finally done! It’s taken hundreds of contributors and thousands of commits to get here, but what a destination: Rails 5.0 is without a doubt the best, most complete version of Rails yet. It’s incredible that this community is still going so strong after so long. Thanks to everyone who helped get us here.

The two star features of Rails 5.0 are as follows:

Action Cable

Action Cable is a brand-new framework for handling WebSockets in Rails. It’s a completely integrated solution for managing connections, a channels layer for server-side processing, and a JavaScript layer for client-side interaction. It’s incredibly easy to use, and makes designing live features like chat, notifications, and presence so much easier. It’s what’s powering all those features of Basecamp 3, if you want to see it in action.

What’s really lovely about Action Cable is that you get access to your entire Active Record and PORO domain model in your WebSockets work. We even added a brand-new ActionController::Renderer system that makes it trivial to render your templates outside of controllers, when you want to reuse server-side templates for WebSocket responses.

In development, Action Cable runs in-process with the rest of your app. To do this, we’ve switched the default development server from Webrick to Puma. In production, you may well want to run Action Cable servers in their own processes. That’s how we run it at Basecamp at scale.

Special thanks to Pratik Naik, Javan Makhmali and Matthew Draper for their formative work on Action Cable.

API mode

Rails is not only a great choice when you want to build a full-stack application that uses server-side rendering of HTML templates, but also a great companion for the new crop of client-side JavaScript or native applications that just needs the backend to speak JSON. We’ve made this even clearer now with the new –api mode. If you create a new Rails application using rails new backend --api, you’ll get a slimmed down skeleton and configuration that assumes you’ll be working with JSON, not HTML.

There’s still more work to be done on this feature, but we’re off to a great start. By default, API mode just relies on #to_json calls on model classes. But you can either use Jbuilder, Active Model Serializers, or look at the new JSONAPI::Resources project for a more advanced solution.

Thanks in particular to Santiago Pastorino and Jorge Bejar for making this happen.

Other highlights

  • One Rails Command instead of the split-brain setup between rake and rails, so now it’s bin/rails db:migrate instead of bin/rake db:migrate (herding by Kasper Timm Hansen).
  • New Attributes API by Sean Griffin.
  • The test runner now reports failures inline, so you don’t have to complete the suite to see what went wrong.
  • ApplicationRecord has been born as a default parent class of all models created by the generators.
  • ActiveRecord::Relation#in_batches makes it much easier to deal with record work in batches at a time to lessen memory overloads.
  • Post.where(‘id = 1’).or(Post.where(‘id = 2’)) gives you exactly what you’d think!
  • No more accidentally halting Active Record callbacks because the last statement is false. Now you throw(:abort) explicitly!

You should really checkout the CHANGELOGs, though. There’s just so much new and good stuff available in all the frameworks:

Rails 5.0 also ships with Turbolinks 5 – the one with native iOS and Android wrapper implementations! If you’ve dismissed Turbolinks in the past, I urge you to checkout Sam Stephenson’s RailsConf presentation: Turbolinks 5: I Can’t Believe It’s Not Native!.

There’s even more detail in the full Rails 5.0 release notes and Claudio B. did a nice little slide deck walking through some of his favorite improvements (and removals!). And I did a brand-new let’s build a blog in Rails 5 video to demonstrate the basics.

Your dynamic release manager duo for Rails 5.0 was Eileen M. Uchitelle and Sean Griffin. And the undisputed PR merge champ was Rafael França!

Note: As per our maintenance policy, the release of Rails 5.0 will mean that bug fixes will only apply to 5.0.x, regular security issues to 5.0.x and 4.2.x, and severe security issues also to 5.0.x and 4.2.x (but when 5.1 drops, to 5.1.x, 5.0.x, and 4.2.x). This means 4.1.x and below will essentially be unsupported! Ruby 2.2.2+ is now also the only supported version of Rails 5.0+.

This Week In Rails: 5.0.0.rc2 release, bugfixes, and more!

Hello everyone! This is Greg bringing latest news from the Rails community.

This week’s Rails Contributors

22 great people helped this week to move the Rails framework forward! If you want to join these folks, have a look at the issues list.

Rails 5.0.0.rc2 release!

Rails 5 RC2 has been released with a lot of bug fixes and polishing. We are one step closer to the final release!


Fix rails/info routes for apps with globbing route

The /rails/info routes were inaccessible in apps with a catch-all route, as they were being appended after the globbing route and would never be matched.

Fix db:structure:load silent failure on PostgresSQL error

The db:structure:load  task silently failed if there was any SQL error, but with this commit, now it will report the error.


Improved db:structure:dump

To avoid unnecessary diffs in the db structure dump, the –skip-comments flag is passed to the mysqldump  command from now on.


datetime_field change

The datetime_tag helper now generates an input tag with the type of datetime-local.

Wrapping Up

That’s it from This Week in Rails! There were many other great contributions, too numerous to list here, but feel free to check them out!

Until next week!

Rails 5.0.0.rc2

We’re happy to announce Rails 5 RC2 has been released.

We continue to work torwards the final Rails 5 release. Between RC1 and RC2 Rails got 91 commits! That’s a whole lot of bug fixes and polishing!

To view the changes for each gem, please read the changelogs on GitHub:

This Week In Rails: smarter file update checker, testable custom queue adapters and more!

Hello everyone! This is Roque bringing latest news from the Rails community.

This Week’s Rails Contributors

This week 23 people contributed to Rails. We also got 4 first time contributors. Welcome aboard folks and keep it going!


Fix digesting non-HTML templates when name conflicts

This fixes a scenario that caused incorrect template digests for */* requests that render non-HTML (e.g. JSON) templates. The HTML template was being used to compute the cache instead of the requested type.

Prevent the FinderMethods#exists? from raising RangeError

It will return a boolean value instead of going 💥 when value is out range.


The file update checker will boot once per process

The checker will now play nice with multi-threaded web servers like Puma. Please read the pull request for more details.

Custom queue adapters will now work with Active Job tests

If you have a custom queue adapter for Active Job, you can override the method queue_adapter_for_test in your tests to take advantage of the test helpers provided.

Wrapping Up

That’s it from This Week in Rails! There were many other great contributions, too numerous to list here, but feel free to check them out!

Until next week!

This Week In Rails: quieter loggers, faster delegators, and smarter defaults!

Ahoy hoy! Tim (aka Godfrey[9]) here bringing you all the latest from the Rails community. It’s been yet another killer week of activity as we continue to refine Rails 5 ahead of its upcoming launch 🚀. Don’t touch that dial - it’s gonna be a helluva show!

This Week’s Rails Contributors

This week saw contributions from 26 fabulous people. 3 of those had a commit merged into Rails for the very first time. A big thank you to you all! ❤️

If you fancy seeing yourself up there next week, why not take a peek at the list of current issues? Improvements to the documentation can also be a great place to start!

Rails 5: The Tour

Last week brought us an updated look at Rails by none other than DHH himself. The video offers a whirlwind tour of some of the most powerful features of the framework for newcomers in a tutorial that gets a blog set up in around 20 minutes. It also offers something for those looking to integrate newer features into their existing Ruby on Rails applications.


#send_file can terminate the callback cycle when used in a before_action

A recent regression caused #send_file to fail to halt the request cycle when used in a before_action. This is because the callback terminator checks for @_response_body , which is no longer set by #send_file. This fix updated to use #performed? instead.

Broadcasting properly delegates #silence to all logs

If you use broadcasting to send messages to multiple loggers, you may have found that it does not silence all of them when told to do so. The fix updated to properly delegate #silence to all.


Delegation gets a boost by leveraging Kernel#caller_locations

Kernel#caller_locations was introduced in MRI 2.0, and outperforms Kernel#caller in Module#delegate by around 10%. For the author this resulted in a faster boot time.

Framework defaults file gets a spring clean

The new_framework_defaults file got a spruce this week, and documentation was updated to include better advice for upgrading to the new defaults from older apps. 

The change also utilizes the update flag in several places to provide better messages catered for those only on the upgrade path.

Wrapping Up

That’s it from This Week in Rails! There were many other great contributions, too numerous to list here, but feel free to check them out!

Until next week!

This Week in Rails: An Apology, Initializer Changes, and More!

Hey, team. Todd here, bringing you another edition of This Week in Rails! Due to a scheduling mishap, we missed an issue last week - we won’t cover it here, but I encourage you to check out the repo activity during that period.

Anyway, let’s get to the exciting stuff from this week!

This Week in Rails – Now in Korean!

First off, a very special thanks to Suhan Lee for translating our newsletter into Korean! He’s going to try to translate each newsletter going forward. If you’re interested in providing more translations, feel free to get in touch with Godfrey.

This Week’s Contributors

We had 25 of you lovely individuals contribute code and documentation to Rails this week. You all rock! Keep the contributions coming!

New Stuff

Collapse Default Initializers Into a Single File

A late addition to Rails 5: default Rails initializers will no longer live in their own files. Instead, a new new_framework_defaults.rb file will be included in new apps generated with Rails 5.


Add WebSocket and logger Configuration Options for Action Cable

You can now configure your own WebSocket and logger options when using Action Cable.

Slim Down Active Record YAML Dumps

This patch decreases the size of model dumps to YAML - in some cases by a whopping 80%!


Fixed Issue Chaining #exists? to #includes

Sean was able to fix an issue where chaining #exists? on #includes would raise an error. It sounds like there’s more work to do here yet, so I encourage giving the commit message a look-see.

ActiveRecord::Base#hash Should Differ Between Classes

Previously, there was an issue where it was possible to have collisions if #hash was called on two different models with the same ID. This is now fixed on master.

Remove OpenSSL Deprecation Warnings

This patch fixes deprecation warnings caused by the OpenSSL::Cipher::Cipher namespace changing to simply OpenSSL::Cipher.

Wrapping Up

That’s a wrap for This Week in Rails! There were plenty of other things going on, so feel free to jump in and check them out yourself!

See you next week!

This Week In Rails: Ruby 2.4 Integer, Action Mailer rescued and more!

Shhh, stay quiet! Rails 5.0 lurks just around the corner and it’s a mean beast. 

Rails’ maintainers, computer scient(-ish)sts, spliced commit DNA merged long ago in hopes of creating a better web framework. The result is Jurrails Park. 

Here’s Kasper alongside self-volunteering co-editor Jeff Goldblum, saying: 

They were so preoccupied with whether or not they could, they didn’t stop to think if they should.

This Weeks Rails Contributors

Contributors! Contributors! Contributors!

62 commits and 22 people makes us a happy newsletter team ❤️

Fixnum + Bignum = Integer

The next version of Ruby, 2.4,  unifies Fixnum and Bignum into Integer. Have no fear, Rails is already ready with both forward compatibility, backward compatibility and all around compatible compatibility. Int’ no Fix’ too Big’, folks.

Action Mailer: rescue_from and more

Action Mailer can now rescue itself from exceptions with rescue_from

This lets the mailer handle errors from the delivering job when run with Active Job. 

Third, the exhaustively documented pull request changes how rescue_from handles Exception causes. Read more.


Support nested calls to #suppress

Calling suppress within another suppression on the same class was previously a let down. 

Now the method doesn’t take its name too seriously and all should be good.


Relation blocked Enumerable count

One of the first Rails 5.1 features brings the framework appropriately forward. Literally by forwarding count on a Relation to Enumerable when passed a block.

Time#all_day meet Date#all_day

Rails has long had Time#all_day to really expand the horizon of past times. Now Date gets to go all_day too.

Though personally, dating for a whole day sounds pretty extreme, but kids these days ¯\_(ツ)_/¯

Wrapping Up

That concludes our report for this week. There were plenty of other things going on, so feel free to jump in and check them out yourself!

This Week In Rails 💯: RailsConf recap & Rails 5.0 RC 1 is out!

RailsConf 2016

Live from RailsConf, happy 100th newsletter from Godfrey, Claudio, Vipul, Roque and Prathamesh (plus Kasper and Jon joining remotely).

The train from Kansas City is leaving the station soon. Just in time for a quick recap of what happened at RailsConf 2016 and this week in Rails.

This Week’s Rails Contributors

This week 26 people contributed to Rails, including a first-time contributor. Thanks to your support, we are on our way to almost 5,000 all-time contributors!

Rails 5.0 RC “RaceCar” 1 is here!

Jeremy promised in his keynote that Rails 5 RC 1 will be released during the conference and it is here now!

Another key milestone towards the final Rails 5 release.

🚆 RailsConf 🚆

Keynote and lightning talks on YouTube

In the next weeks, Confreaks will be posting individual videos for each session. Meanwhile, you can still catch the full-day videos for Day 1, Day 2, and Day 3.

If you attended the RailsConf, don’t forget to let the organizers know your feedback before May 13th!

New Stuff

Allow accessing all helpers at the controller level

With this helper proxy, users can reuse helpers in the controller without having to include all the modules related to view context.

Add ActiveModel::RangeError

When provided with large numbers, Active Model now fails with a new ActiveModel::RangeError that makes it easier to rescue from, and inherits from RangeError to maintain backward compatibility.


Ensure compatibility between Rails Session and Rack Session

Rails session is now compatible with other Rack frameworks like Sinatra that are mounted in Rails. They can also use session tooling of Rails without any issues now.

Wrapping Up

Meeting you all at RailsConf was a lot of fun. And if you haven’t seen us up on stage during the lightning talks, here is the YouTube link of “Goodfry and his boy band”.

That concludes our report for this week. There were plenty of other things going on, so feel free to jump in and check them out yourself. Also look out for the announcement of all the videos from RailsConf on Confreaks!

See you next year at RailsConf 2017 in Phoenix AZ!