1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Require pg~>0.18 to ensure Ruby 2.2 compatibility

Versions of the pg gem earlier than 0.18.0 cannot be used safely with Ruby 2.2.
Specifically, pg 0.17 when used with Ruby 2.2 has a known bug that causes
random bits to be added to the end of strings. Further explanation here:
https://bitbucket.org/ged/ruby-pg/issue/210/crazy-bytes-being-added-to-record
This commit is contained in:
Matt Brictson 2015-03-11 22:12:47 -07:00
parent fd3e63e2d9
commit ba7532700f
2 changed files with 7 additions and 2 deletions

View file

@ -1,3 +1,8 @@
* Increase pg gem version requirement to `~> 0.18`. Earlier versions of the
pg gem are known to have problems with Ruby 2.2.
*Matt Brictson*
* Correctly dump `serial` and `bigserial`.
*Ryuta Kamizono*

View file

@ -12,8 +12,8 @@ require "active_record/connection_adapters/statement_pool"
require 'arel/visitors/bind_visitor'
# Make sure we're using pg high enough for PGResult#values
gem 'pg', '~> 0.15'
# Make sure we're using pg high enough for Ruby 2.2+ compatibility
gem 'pg', '~> 0.18'
require 'pg'
require 'ipaddr'