CanCanCan 2.0 is out

The projects gets a new major update

Alessandro Rodi
2 min readMay 18, 2017

After few months CanCanCan has finally a new major version: 2.0.

The CanCanCommunity searched for long time for new maintainers and is now active again thanks to Renuo.

There are many important changes in the new version but very few new features. We thought it was time to bring the project back on track and drop support for a lot of unnecessary features.

Drop support for Mongoid and Sequel

Yes, these two ORMs are not supported anymore. They’ll be extracted in two different gems cancancan-mongoid and cancancan-sequel and we’ll look for maintainers for them. People using these libraries need to stick to gem cancancan, '< 2.0'.

Drop support for ruby < 2.2.0

Again, we do not want to keep supporting old versions of ruby which are not supported by ruby community itself. If you use CanCanCan 2.0 you also need upgrade your ruby version.

Drop support for Rails 3.2

We are in the era of Rails 5.1 and is time to say goodbye to Rails 3.2. You’ll need at least Rails 4.2 from now on.

Removed deprecated methods and options

Some methods and options were deprecated since a long time and they are now gone. We removed controller methods skip_authorizationand unauthorized! and removed the options nested, nameand resource.

Introduced Rubocop

The entire project is now checked against Rubocop and follows the code style best practices. This makes some order in the code style which was not uniform in the last year, since many contributions came from many different people.

Please refer to the Project on GitHub to see the list of changes we did in this version.

And, by the way, the gem is now 20.5KB instead of 50KB.



Alessandro Rodi

Open Source Software Engineer at Renuo AG. Located in Zürich. I do stuff. Sometimes.