Patch #28505

Update pg gem to 1.0

Added by Marius BALTEANU 8 months ago. Updated 7 months ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Go MAEDA% Done:

0%

Category:Gems support
Target version:4.0.0

Description

Rails 5.1.5 supports pg gem 1.0

https://github.com/rails/rails/blob/v5.1.6/activerecord/CHANGELOG.md#rails-515-february-14-2018

Unfortunately, I can't run the test suite on PG as database engine.


Related issues

Duplicated by Redmine - Feature #27985: Support of gem pg 1.0.0 (PostgreSQL) Closed
Copied from Redmine - Patch #28504: Update mysql2 gem to 0.5.0 Closed

Associated revisions

Revision 17358
Added by Go MAEDA 7 months ago

Update pg gem to 1.0 (#28505).

Patch by Mizuki ISHIKAWA.

History

#1 Updated by Marius BALTEANU 8 months ago

  • Copied from Patch #28504: Update mysql2 gem to 0.5.0 added

#2 Updated by Go MAEDA 8 months ago

  • Duplicated by Feature #27985: Support of gem pg 1.0.0 (PostgreSQL) added

#3 Updated by Mizuki ISHIKAWA 8 months ago

  • pg 1.0.0
  • postgresql 9.5.3

I confirmed that all the tests are green under the above conditions.

diff --git a/Gemfile b/Gemfile
index a3f99a1ec..94dc31301 100644
--- a/Gemfile
+++ b/Gemfile
@@ -62,7 +62,7 @@ if File.exist?(database_file)
       when 'mysql2'
         gem "mysql2", "~> 0.4.6", :platforms => [:mri, :mingw, :x64_mingw]
       when /postgresql/
-        gem "pg", "~> 0.18.1", :platforms => [:mri, :mingw, :x64_mingw]
+        gem "pg", "~> 1.0.0", :platforms => [:mri, :mingw, :x64_mingw]
       when /sqlite3/
         gem "sqlite3", "~>1.3.12", :platforms => [:mri, :mingw, :x64_mingw]
       when /sqlserver/

#4 Updated by Go MAEDA 8 months ago

  • Target version set to 4.0.0

Mizuki ISHIKAWA wrote:

  • pg 1.0.0
  • postgresql 9.5.3

I confirmed that all the tests are green under the above conditions.

Thanks, setting target version to 4.0.0.

#5 Updated by Go MAEDA 8 months ago

pg 1.0.0 supports PostgreSQL 9.2 and later. If we update pg gem to 1.0.0, Redmine cannot run on some operating systems such as CentOS 6 (PostgreSQL is 8.4).

It may be too early to update to pg 1.0.0.

#6 Updated by Shinichi Yanagisawa 7 months ago

pg 1.0.0 supports PostgreSQL 9.2 and later. If we update pg gem to 1.0.0, Redmine cannot run on some operating systems such as CentOS 6 (PostgreSQL is 8.4).

It may be too early to update to pg 1.0.0.

PostgreSQL 8.4 is not a supported version in the PG community, so to update pg 1.0.0 is NOT too early in terms of security.
https://www.postgresql.org/support/versioning/

Anyway, CentOS 6 and 7 does not support Ruby 2.2 or higher as standard, but Redmine 4.0 will require Ruby 2.2 or higher. It means in any case Redmine 4.0 does not work on CentOS with only standard repository. I think you should consider the OS version that supports Ruby 2.2 or higher as a criteria and present PostrgreSQL's workaround same as Ruby installation if they use an OS like CentOS.

#7 Updated by Go MAEDA 7 months ago

"Maintenance Support 1 Phase" for RHEL 6 and "Full Updates phase" for CentOS 6 ended on May 10, 2017. RHEL / CentOS 6 users should prioritize to update the operating system rather than Redmine.

https://access.redhat.com/support/policy/updates/errata#Life_Cycle_Dates
https://wiki.centos.org/About/Product

#8 Updated by Go MAEDA 7 months ago

  • Status changed from New to Closed
  • Assignee set to Go MAEDA

Committed. Thank you all for the contribution.

Also available in: Atom PDF