---
title: "Rails 6 Blogs"
description: "BigBinary blog posts in the Rails 6 category."
canonical_url: "https://www.bigbinary.com/blog/categories/rails-6"
markdown_url: "https://www.bigbinary.com/blog/categories/rails-6.md"
---

# Rails 6 Blogs

BigBinary blog posts in the Rails 6 category.

## Posts

### Rails 6 adds support to persist timezones of Active Job

[Rails 6 adds support to persist timezones of Active Job](https://www.bigbinary.com/blog/rails-6-add-timezone-support-in-active-job)

- Author: Chetan Gawai
- Published: September 1, 2020
- Categories: Rails 6, Rails

Rails 6 now records current timezone of Active Job

### Rails 6 adds including & excluding method on Enumerables

[Rails 6 adds including & excluding method on Enumerables](https://www.bigbinary.com/blog/rails-6-adds-array-including-excluding-and-enumerable-including-excluding)

- Author: Akhil Gautam
- Published: August 18, 2020
- Categories: Rails 6, Rails

Rails 6 adds Array#including/excluding and Enumerable#including/excluding

### Rails 6 fixes after_commit callback invocation bug

[Rails 6 fixes after_commit callback invocation bug](https://www.bigbinary.com/blog/rails-6-fixes-a-bug-where-after_commit-callbacks-are-called-on-failed-update-in-a-transaction-block)

- Author: Amit Choudhary
- Published: February 25, 2020
- Categories: Rails 6, Rails

Rails 6 fixes a bug where after_commit callbacks are called on failed update in
a transaction block

### Rails 6 adds rails db:prepare to migrate or setup a database

[Rails 6 adds rails db:prepare to migrate or setup a database](https://www.bigbinary.com/blog/rails-6-adds-rails-db-prepare-to-migrate-or-setup-a-database)

- Author: Akhil Gautam
- Published: December 10, 2019
- Categories: Rails 6, Rails

Rails 6 adds rails db:prepare to migrate or setup a database if it doesn't exist

### Rails 6 adds guard against DNS Rebinding attacks

[Rails 6 adds guard against DNS Rebinding attacks](https://www.bigbinary.com/blog/rails-6-adds-guard-against-dns-rebinding-attacks)

- Author: Midhun Krishna
- Published: November 5, 2019
- Categories: Rails 6, Rails

Rails 6 adds guard against DNS Rebinding attacks by whitelisting hosts via
configuration

### Rails 6 adds ActiveStorage::Blob#open

[Rails 6 adds ActiveStorage::Blob#open](https://www.bigbinary.com/blog/rails-6-adds-activestorage-blob-open)

- Author: Akhil Gautam
- Published: October 30, 2019
- Categories: Rails 6, Rails

Rails 6 adds ActiveStorage::Blob#open

### Rails 6 adds ActionMailer#email_address_with_name

[Rails 6 adds ActionMailer#email_address_with_name](https://www.bigbinary.com/blog/rails-6-adds-actionmailer-email_address_with_name)

- Author: Taha Husain
- Published: October 22, 2019
- Categories: Rails 6, Rails

Rails 6 adds email_address_with_name to ActionMailer to properly escape email
addresses with names.

### Rails 6 raises ArgumentError if param contains colon

[Rails 6 raises ArgumentError if param contains colon](https://www.bigbinary.com/blog/rails-6-raises-argumenterror-if-custom-param-contains-a-colon)

- Author: Amit Choudhary
- Published: October 15, 2019
- Categories: Rails 6, Rails

Rails 6 raises ArgumentError if custom param contains a colon

### Rails 6 introduces new code loader called Zeitwerk

[Rails 6 introduces new code loader called Zeitwerk](https://www.bigbinary.com/blog/rails-6-introduces-new-code-loader-called-zeitwerk)

- Author: Midhun Krishna
- Published: October 8, 2019
- Categories: Rails 6, Rails

Rails 6 introduces new code loader named Zeitwerk with better Ruby semantics and
threadsafety

### Rails 6 adds ActiveSupport::ActionableError

[Rails 6 adds ActiveSupport::ActionableError](https://www.bigbinary.com/blog/rails-6-adds-active-support-actionable-error)

- Author: Taha Husain
- Published: October 1, 2019
- Categories: Rails 6, Rails

Rails 6 adds support for dispatching actions from error page

### Rails 6 add_foreign_key & remove_foreign_key SQLite3

[Rails 6 add_foreign_key & remove_foreign_key SQLite3](https://www.bigbinary.com/blog/rails-6-adds-add_foreign_key-and-remove_foreign_key-for-sqlite3)

- Author: Amit Choudhary
- Published: September 24, 2019
- Categories: Rails 6, Rails

Rails 6 adds add_foreign_key and remove_foreign_key for SQLite3

### Rails 6 adds ActionDispatch::Request::Session#dig

[Rails 6 adds ActionDispatch::Request::Session#dig](https://www.bigbinary.com/blog/rails-6-adds-actiondispatch-request-session-dig)

- Author: Amit Choudhary
- Published: September 18, 2019
- Categories: Rails 6, Rails

Rails 6 adds ActionDispatch::Request::Session#dig

### Marking arrays of translations safe using html suffix

[Marking arrays of translations safe using html suffix](https://www.bigbinary.com/blog/rails-6-marks-arrays-of-translations-as-trusted-safe-by-using-the-_html-suffix)

- Author: Vishal Telangre
- Published: September 11, 2019
- Categories: Rails 6, Rails

Rails 6 marks arrays of translations as trusted safe by using the \_html suffix

### Rails 6 adds filter_attributes on ActiveRecord::Base

[Rails 6 adds filter_attributes on ActiveRecord::Base](https://www.bigbinary.com/blog/rails-6-adds-activerecord-base-filter_attributes)

- Author: Amit Choudhary
- Published: September 3, 2019
- Categories: Rails 6, Rails

Rails 6 adds filter_attributes on ActiveRecord::Base

### ArgumentError for invalid:limit &:precision Rails 6

[ArgumentError for invalid:limit &:precision Rails 6](https://www.bigbinary.com/blog/rails-6-raises-argumenterror-for-invalid-limit-and-precision)

- Author: Amit Choudhary
- Published: August 27, 2019
- Categories: Rails 6, Rails

Rails 6 raises ArgumentError for invalid:limit and:precision

### Rails 6 Pass custom config to ActionCable::Server::Base

[Rails 6 Pass custom config to ActionCable::Server::Base](https://www.bigbinary.com/blog/rails-6-allows-passing-custom-configuration-to-actioncable-server-base)

- Author: Taha Husain
- Published: August 21, 2019
- Categories: Rails 6, Rails

Rails 6 allows passing custom configuration to ActionCable::Server::Base

### Rails 6 adds support of symbol keys

[Rails 6 adds support of symbol keys](https://www.bigbinary.com/blog/rails-6-adds-activesupport-hashwithindifferentaccess-assoc)

- Author: Amit Choudhary
- Published: August 20, 2019
- Categories: Rails 6, Rails

Rails 6 adds support of symbol keys with
ActiveSupport::HashWithIndifferentAccess#assoc

### Rails 6 preserves status of #html_safe?

[Rails 6 preserves status of #html_safe?](https://www.bigbinary.com/blog/rails-6-preserves-status-of-html_safe-on-sliced-and-multiplied-html-safe-strings)

- Author: Vishal Telangre
- Published: August 13, 2019
- Categories: Rails 6, Rails

"Rails 6 preserves status of #html_safe? on HTML safe strings which are sliced
or multiplied using \`ActiveSupport::SafeBuffer#\*\`"

### Recyclable cache keys in Rails

[Recyclable cache keys in Rails](https://www.bigbinary.com/blog/rails-adds-support-for-recyclable-cache-keys)

- Author: Taha Husain
- Published: August 6, 2019
- Categories: Rails 5.2, Rails 6, Rails

Rails added cache_versioning and collection_cache_versioning to support
recyclable cache keys.

### Rails 6 deprecates where.not as NOR & Rails 6.1 as NAND

[Rails 6 deprecates where.not as NOR & Rails 6.1 as NAND](https://www.bigbinary.com/blog/rails-6-deprecates-where-not-working-as-nor-and-will-change-to-nand-in-rails-6-1)

- Author: Taha Husain
- Published: July 31, 2019
- Categories: Rails 6, Rails

Rails 6 adds a deprecation warning for where.not as NOR and will change in Rails
6.1 to NAND

### Rails 6 adds support for Optimizer Hints

[Rails 6 adds support for Optimizer Hints](https://www.bigbinary.com/blog/rails-6-supports-optimizer-hints)

- Author: Vishal Telangre
- Published: July 30, 2019
- Categories: Rails 6, Rails

Rails 6 has added support for Optimizer Hints

### Rails 6 reports object allocations while rendering

[Rails 6 reports object allocations while rendering](https://www.bigbinary.com/blog/rails-6-reports-object-allocations-made-while-rendering-view-templates)

- Author: Vishal Telangre
- Published: July 23, 2019
- Categories: Rails 6, Rails

Rails 6 reports object allocations made while rendering view templates

### Rails 6 adds ActiveRecord::Relation#annotate

[Rails 6 adds ActiveRecord::Relation#annotate](https://www.bigbinary.com/blog/rails-6-adds-annotate-to-activerecord-relation-queries)

- Author: Abhay Nikam
- Published: July 15, 2019
- Categories: Rails 6, Rails

Rails 6 adds ActiveRecord::Relation#annotate to annotate generated SQL queries

### Rails 6 adds hook to Active Job for retry & discard

[Rails 6 adds hook to Active Job for retry & discard](https://www.bigbinary.com/blog/rails-6-adds-hooks-to-activejob-around-retries-and-discards)

- Author: Vishal Telangre
- Published: July 9, 2019
- Categories: Rails 6, Rails

Rails 6 adds hooks to Active Job around retries and discards

### Rails 6 adds support for Multi Environment credentials

[Rails 6 adds support for Multi Environment credentials](https://www.bigbinary.com/blog/rails-6-adds-support-for-multi-environment-credentials)

- Author: Berin Larson
- Published: July 3, 2019
- Categories: Rails 6, Rails

Rails 6 adds support for multi environment credentials

### Rails 6 adds before? and after? to Date and Time

[Rails 6 adds before? and after? to Date and Time](https://www.bigbinary.com/blog/rails-6-adds-before-and-after-to-date-and-time)

- Author: Amit Choudhary
- Published: June 26, 2019
- Categories: Rails 6, Rails

Rails 6 adds before? and after? to Date, DateTime, Time and
ActiveSupport::TimeWithZone classes

### Rails 6 adds Array#extract!

[Rails 6 adds Array#extract!](https://www.bigbinary.com/blog/rails-6-adds-array-extract)

- Author: Amit Choudhary
- Published: June 24, 2019
- Categories: Rails 6, Rails

Rails 6 adds Array#extract!

### Rails 6 adds Enumerable#index_with

[Rails 6 adds Enumerable#index_with](https://www.bigbinary.com/blog/rails-6-adds-enumerable-index_with)

- Author: Amit Choudhary
- Published: June 17, 2019
- Categories: Rails 6, Rails

Rails 6 adds Enumerable#index_with

### Rails 6 adds private option to delegate method

[Rails 6 adds private option to delegate method](https://www.bigbinary.com/blog/rails-6-adds-private-option-to-delegate-method)

- Author: Amit Choudhary
- Published: June 10, 2019
- Categories: Rails 6, Rails

Rails 6 adds private option to delegate method

### Rails 6 allows spaces in postgres table names

[Rails 6 allows spaces in postgres table names](https://www.bigbinary.com/blog/rails-6-allows-spaces-in-postgres-table-names)

- Author: Amit Choudhary
- Published: June 5, 2019
- Categories: Rails 6, Rails

Rails 6 allows spaces in postgres table names

### Rails 6 adds if_not_exists option to create_table

[Rails 6 adds if_not_exists option to create_table](https://www.bigbinary.com/blog/rails-6-adds-if_not_exists-option-to-create_table)

- Author: Amit Choudhary
- Published: May 22, 2019
- Categories: Rails 6, Rails

Rails 6 adds if_not_exists option to create_table

### Rails 6 has added a way to change the database of the app

[Rails 6 has added a way to change the database of the app](https://www.bigbinary.com/blog/rails-6-has-added-a-way-to-change-the-database-of-the-app)

- Author: Prathamesh Sonpatki
- Published: April 30, 2019
- Categories: Rails 6, Rails

It is possible to change the database configuration using a simple command

### Rails 6 adds parallel testing

[Rails 6 adds parallel testing](https://www.bigbinary.com/blog/rails-6-adds-parallel-testing)

- Author: Amit Choudhary
- Published: April 29, 2019
- Categories: Rails 6, Rails

Rails 6 adds parallel testing

### Rails 6 improves ActiveSupport::Notifications::Event

[Rails 6 improves ActiveSupport::Notifications::Event](https://www.bigbinary.com/blog/rails-6-adds-cpu-time-idle-time-and-allocations-to-activesupport-notifications-event)

- Author: Vishal Telangre
- Published: April 24, 2019
- Categories: Rails 6, Rails

Rails 6 adds CPU time, idle time and allocations to
ActiveSupport::Notifications::Event

### Rails 6 allows configuring has_secure_password attribute

[Rails 6 allows configuring has_secure_password attribute](https://www.bigbinary.com/blog/rails-6-allows-configurable-attribute-name-on-has_secure_password)

- Author: Amit Choudhary
- Published: April 23, 2019
- Categories: Rails 6, Rails

Rails 6 allows configurable attribute name on has_secure_password

### Rails 6 allows overriding ActiveModel::Errors#full_message

[Rails 6 allows overriding ActiveModel::Errors#full_message](https://www.bigbinary.com/blog/rails-6-allows-to-override-the-activemodel-errors-full_message-format-at-the-model-level-and-at-the-attribute-level)

- Author: Vishal Telangre
- Published: April 22, 2019
- Categories: Rails 6, Rails

Rails 6 allows to override the ActiveModel::Errors#full_message format at the
model level and at the attribute level

### Rails 6 adds ActiveRecord::Relation#extract_associated

[Rails 6 adds ActiveRecord::Relation#extract_associated](https://www.bigbinary.com/blog/rails-6-adds-activerecord-relation-extract_associated)

- Author: Taha Husain
- Published: April 17, 2019
- Categories: Rails 6, Rails

Rails 6 added ActiveRecord::Relation#extract_associated for extracting
associated records from a relation

### Rails 6 adds implicit_order_column

[Rails 6 adds implicit_order_column](https://www.bigbinary.com/blog/rails-6-adds-implicit_order_column)

- Author: Amit Choudhary
- Published: April 16, 2019
- Categories: Rails 6, Rails

Rails 6 adds implicit_order_column for ordering records implicitly

### Bulk insert support in Rails 6

[Bulk insert support in Rails 6](https://www.bigbinary.com/blog/bulk-insert-support-in-rails-6)

- Author: Vishal Telangre
- Published: April 15, 2019
- Categories: Rails 6, Rails

Rails 6 introduced methods such as insert_all, insert_all! and update_all to
support bulk insert

### Rails 6 drops support for PostgreSQL version less than 9.3

[Rails 6 drops support for PostgreSQL version less than 9.3](https://www.bigbinary.com/blog/rails-6-drops-support-for-postgresql-less-than-9-3)

- Author: Prathamesh Sonpatki
- Published: April 10, 2019
- Categories: Rails 6, Rails

Rails 6 has dropped support for PostgreSQL versions less than 9.3

### Rails 6 requires Ruby 2.5 or newer

[Rails 6 requires Ruby 2.5 or newer](https://www.bigbinary.com/blog/rails-6-requires-ruby-2-5-or-newer)

- Author: Vishal Telangre
- Published: April 9, 2019
- Categories: Rails 6, Rails

Rails 6 requires Ruby 2.5 or newer

### Rails 6 database seed uses inline Active Job adapter

[Rails 6 database seed uses inline Active Job adapter](https://www.bigbinary.com/blog/database-seeding-task-uses-inline-active-job-adapter-in-rails-6)

- Author: Prathamesh Sonpatki
- Published: April 3, 2019
- Categories: Rails 6, Rails

Rails 6 uses inline Active Job adapter for background processing related to
db:seed task

### Rails 6 adds ActiveRecord::Relation#reselect

[Rails 6 adds ActiveRecord::Relation#reselect](https://www.bigbinary.com/blog/rails-6-adds-activerecord-relation-reselect)

- Author: Abhay Nikam
- Published: April 2, 2019
- Categories: Rails 6, Rails

Rails 6 adds ActiveRecord::Relation#reselect method.

### Rails 6 adds ActiveModel::Errors#of_kind?

[Rails 6 adds ActiveModel::Errors#of_kind?](https://www.bigbinary.com/blog/rails-6-adds-activemodel-errors-of_kind-)

- Author: Amit Choudhary
- Published: April 1, 2019
- Categories: Rails 6, Rails

Rails 6 adds ActiveModel::Errors#of_kind?

### Rails 6 shows routes in expanded format

[Rails 6 shows routes in expanded format](https://www.bigbinary.com/blog/rails-6-shows-routes-in-expanded-format)

- Author: Prathamesh Sonpatki
- Published: March 27, 2019
- Categories: Rails 6, Rails

Rails 6 has added ability to show the routes in an expanded format

### Rails 6 adds ActiveModel::Errors#slice!

[Rails 6 adds ActiveModel::Errors#slice!](https://www.bigbinary.com/blog/rails-6-adds-activemodel-errors-slice)

- Author: Amit Choudhary
- Published: March 26, 2019
- Categories: Rails 6, Rails

Rails 6 adds ActiveModel::Errors#slice!

### Rails 6 adds create_or_find_by and create_or_find_by!

[Rails 6 adds create_or_find_by and create_or_find_by!](https://www.bigbinary.com/blog/rails-6-adds-create_or_find_by)

- Author: Amit Choudhary
- Published: March 25, 2019
- Categories: Rails 6, Rails

Rails 6 adds create_or_find_by and create_or_find_by! to find record if creation
fails because of unique constraints

### Rails 6 raises ActiveModel::MissingAttributeError

[Rails 6 raises ActiveModel::MissingAttributeError](https://www.bigbinary.com/blog/rails-6-raises-activemodel-missingattributeerror-when-update_columns-is-used-with-non-existing-attribute)

- Author: Amit Choudhary
- Published: March 20, 2019
- Categories: Rails 6, Rails

updated_columns raises ActiveModel::MissingAttributeError when used with a
non-existing attribute in Rails 6

### Rails 6 ActiveRecord::Base.configurations

[Rails 6 ActiveRecord::Base.configurations](https://www.bigbinary.com/blog/rails-6-changed-activerecord-base-configurations-result-to-an-object)

- Author: Amit Choudhary
- Published: March 19, 2019
- Categories: Rails 6, Rails

Rails 6 changed ActiveRecord::Base.configurations result to an object instead of
a hash

### Rails 6 shows unpermitted params in logs in color

[Rails 6 shows unpermitted params in logs in color](https://www.bigbinary.com/blog/rails-6-shows-unpermitted-params-in-logs-in-color)

- Author: Prathamesh Sonpatki
- Published: March 18, 2019
- Categories: Rails 6, Rails

The unpermitted params are shown in red color for better visibility

### Rails 6 delete_by, destroy_by ActiveRecord::Relation

[Rails 6 delete_by, destroy_by ActiveRecord::Relation](https://www.bigbinary.com/blog/rails-6-adds-activerecord-relation-delete_by-and-activerecord-relation-destroy_by)

- Author: Abhay Nikam
- Published: March 13, 2019
- Categories: Rails 6, Rails

In Rails 6, ActiveRecord::Relation has two new methods \`delete_by\` and
\`destroy_by\`.

### Rails 6 adds ActiveRecord::Relation#touch_all

[Rails 6 adds ActiveRecord::Relation#touch_all](https://www.bigbinary.com/blog/rails-6-adds-activerecord-relation-touch-all)

- Author: Amit Choudhary
- Published: March 12, 2019
- Categories: Rails 6, Rails

Rails 6 added pick method on ActiveRecord::Relation#touch_all to touch multiple
records in a go

### Rails 6 adds negative scopes on enum

[Rails 6 adds negative scopes on enum](https://www.bigbinary.com/blog/rails-6-adds-negative-scopes-on-enum)

- Author: Abhay Nikam
- Published: March 6, 2019
- Categories: Rails 6, Rails

Rails 6 adds default negative scopes for all defined enum on model

### Rails 6 adds ActiveRecord::Relation#pick

[Rails 6 adds ActiveRecord::Relation#pick](https://www.bigbinary.com/blog/rails-6-adds-activerecord-relation-pick)

- Author: Prathamesh Sonpatki
- Published: January 16, 2019
- Categories: Rails 6

Rails 6 added a shortcut to select first value for a group of columns from a
relation

## Links

- [Human page](https://www.bigbinary.com/blog/categories/rails-6)
