Feature #30356

Drop Ruby 2.2 support

Added by Go MAEDA 9 months ago. Updated 8 months ago.

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

0%

Category:Ruby support
Target version:4.1.0
Resolution:Fixed

Description

Currently, Redmine 4.0 supports Ruby 2.2. But the latest nokogiri gem 1.10.0 supports 2.3 and later, does not 2.2. So, we cannot update nogogiri gem to 1.10.0 as long as Redmine officially supports Ruby 2.2.

However, it is necessary to update nokogiri to 1.10.0 in order to support Ruby 2.6 because older nokogiri does not support Ruby 2.6 on Windows (https://github.com/sparklemotion/nokogiri/pull/1850).

We have to choose the Ruby version we support, 2.2 or 2.6. Needless to say, Redmine 4.0 should support Ruby 2.6 rather than retired 2.2.

remove-code-for-ruby-two-point-two.diff Magnifier (1.18 KB) Go MAEDA, 2019-02-03 06:54


Related issues

Related to Redmine - Patch #30241: Update nokogiri gem (~> 1.10.0) Closed
Blocks Redmine - Feature #29946: Update i18n gem (~> 1.6.0) Closed

Associated revisions

Revision 17887
Added by Go MAEDA 8 months ago

Drop Ruby 2.2 support (#30356).

History

#1 Updated by Go MAEDA 9 months ago

  • Related to Patch #30241: Update nokogiri gem (~> 1.10.0) added

#2 Updated by Go MAEDA 9 months ago

#3 Updated by Pavel Rosický 9 months ago

What about just locking nokogiri 1.9.0 for Ruby 2.2?

#4 Updated by Go MAEDA 9 months ago

Pavel Rosický wrote:

What about just locking nokogiri 1.9.0 for Ruby 2.2?

You are right. I quite forgot about it. This should work.

Index: Gemfile
===================================================================
--- Gemfile    (revision 17777)
+++ Gemfile    (working copy)
@@ -14,7 +14,7 @@
 gem "mail", "~> 2.7.1" 
 gem "csv", "~> 3.0.1" if RUBY_VERSION >= "2.3" && RUBY_VERSION < "2.6" 

-gem "nokogiri", "~> 1.9.0" 
+gem "nokogiri", (RUBY_VERSION >= "2.3" ? "~> 1.10.0" : "~> 1.9.1")
 gem "i18n", "~> 0.7.0" 

 # Windows does not include zoneinfo files, so bundle the tzinfo-data gem

#5 Updated by Marius BALTEANU 9 months ago

In my opinion, we should drop Ruby 2.2 support in 4.1.0.

#6 Updated by Go MAEDA 9 months ago

  • Assignee set to Jean-Philippe Lang
  • Target version set to 4.0.1

Jean-Philippe Lang is considering to drop Ruby 2.2 support in 4.0-stable (see #30161#note-3). I will leave this issue to him.

#7 Updated by Marius BALTEANU 9 months ago

Go MAEDA wrote:

Jean-Philippe Lang is considering to drop Ruby 2.2 support in 4.0-stable (see #30161#note-3). I will leave this issue to him.

Agree.

I proposed 4.1.0 because 4.0.1 will be a maintenance release (mostly with bug fixes and small changes) and dropping support for Ruby 2.2 could have an important impact:
  • Server administrators will need to update the Ruby version on installations with Ruby 2.2.
  • The codebase of the plugins compatible with 4.0 must be rechecked by their developers to support 4.0.1.

Discussions on the same topic: #25538

#8 Updated by Go MAEDA 9 months ago

We don't have to drop Ruby 2.2 support in a hurry for now. And I think there isn't any harm to commit the patch #30356#note-4 to the trunk and 4.0-stable.

I would like to commit #30356#note-4 as a part of #30241. What do you all think?

#9 Updated by Marius BALTEANU 9 months ago

Go MAEDA wrote:

We don't have to drop Ruby 2.2 support in a hurry for now. And I think there isn't any harm to commit the patch #30356#note-4 to the trunk and 4.0-stable.

I would like to commit #30356#note-4 as a part of #30241. What do you all think?

I’m totally agree.

#10 Updated by Go MAEDA 9 months ago

  • Status changed from New to Closed
  • Assignee deleted (Jean-Philippe Lang)
  • Target version deleted (4.0.1)

Uses Nokogiri 1.9 for Ruby 2.2, 1.10 for Ruby >=2.3. We don't have to drop support for Ruby 2.2. See r17778.

#11 Updated by Go MAEDA 9 months ago

#12 Updated by Go MAEDA 9 months ago

  • Resolution set to Invalid

#13 Updated by Marius BALTEANU 9 months ago

  • Status changed from Closed to Reopened
  • Target version set to 4.1.0

I'm reopening this for 4.1.0.

#14 Updated by Go MAEDA 9 months ago

The attached patch removes code for Ruby 2.2.

#15 Updated by Go MAEDA 8 months ago

#16 Updated by Go MAEDA 8 months ago

  • Status changed from Reopened to Closed
  • Assignee set to Go MAEDA
  • Resolution changed from Invalid to Fixed

Committed. Redmine 4.1 supports Ruby 2.3 and later.

#17 Updated by Marius BALTEANU 7 months ago

#18 Updated by Marius BALTEANU 7 months ago

Also available in: Atom PDF