Skip to content

Commit 64b119c

Browse files
committed
🐛 The cake is a lie
- erb v2.2 was never compatible with Ruby 2.3
1 parent 66715e4 commit 64b119c

2 files changed

Lines changed: 22 additions & 1 deletion

File tree

Appraisals

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
# - Broken workflow indicates that a new contributor will have a bad time
2323
#
2424
appraise "unlocked_deps" do
25+
gem "erb"
2526
eval_gemfile "modular/coverage.gemfile"
2627
eval_gemfile "modular/documentation.gemfile"
2728
eval_gemfile "modular/style.gemfile"
@@ -30,6 +31,7 @@ end
3031
# Used for head (nightly) releases of ruby, truffleruby, and jruby.
3132
# Split into discrete appraisals if one of them needs a dependency locked discretely.
3233
appraise "head" do
34+
gem "erb"
3335
gem "mutex_m", ">= 0.2"
3436
gem "stringio", ">= 3.0"
3537
gem "benchmark", "~> 0.4", ">= 0.4.1"
@@ -38,64 +40,80 @@ end
3840
# Used for current releases of ruby, truffleruby, and jruby.
3941
# Split into discrete appraisals if one of them needs a dependency locked discretely.
4042
appraise "current" do
43+
gem "erb"
4144
gem "mutex_m", ">= 0.2"
4245
gem "stringio", ">= 3.0"
4346
end
4447

4548
appraise "ruby-2-3" do
49+
# The cake is a lie. erb v2.2, the oldest release on RubyGems.org, was never compatible with Ruby 2.3.
50+
# This means we have no choice but to use the erb that shipped with Ruby 2.3
51+
# /opt/hostedtoolcache/Ruby/2.3.8/x64/lib/ruby/gems/2.3.0/gems/erb-2.2.2/lib/erb.rb:670:in `prepare_trim_mode': undefined method `match?' for "-":String (NoMethodError)
52+
# spec.add_development_dependency("erb", ">= 2.2") # ruby >= 2.3.0, not SemVer, old rubies get dropped in a patch.
4653
end
4754

4855
appraise "ruby-2-4" do
56+
gem "erb"
4957
end
5058

5159
appraise "ruby-2-5" do
60+
gem "erb"
5261
end
5362

5463
appraise "ruby-2-6" do
64+
gem "erb"
5565
gem "mutex_m", "~> 0.2"
5666
gem "stringio", "~> 3.0"
5767
end
5868

5969
appraise "ruby-2-7" do
70+
gem "erb"
6071
gem "mutex_m", "~> 0.2"
6172
gem "stringio", "~> 3.0"
6273
end
6374

6475
appraise "ruby-3-0" do
76+
gem "erb"
6577
gem "mutex_m", "~> 0.2"
6678
gem "stringio", "~> 3.0"
6779
end
6880

6981
appraise "ruby-3-1" do
82+
gem "erb"
7083
gem "mutex_m", "~> 0.2"
7184
gem "stringio", "~> 3.0"
7285
end
7386

7487
appraise "ruby-3-2" do
88+
gem "erb"
7589
gem "mutex_m", "~> 0.2"
7690
gem "stringio", "~> 3.0"
7791
end
7892

7993
appraise "ruby-3-3" do
94+
gem "erb"
8095
gem "mutex_m", "~> 0.2"
8196
gem "stringio", "~> 3.0"
8297
end
8398

8499
# Only run security audit on latest Ruby version
85100
appraise "audit" do
101+
gem "erb"
86102
gem "mutex_m", "~> 0.2"
87103
gem "stringio", "~> 3.0"
88104
end
89105

90106
# Only run coverage on latest Ruby version
91107
appraise "coverage" do
108+
gem "erb"
92109
gem "mutex_m", "~> 0.2"
93110
gem "stringio", "~> 3.0"
94111
eval_gemfile "modular/coverage.gemfile"
95112
end
96113

97114
# Only run linter on latest Ruby version (but, in support of oldest supported Ruby version)
98115
appraise "style" do
116+
gem "erb"
99117
gem "mutex_m", "~> 0.2"
100118
gem "stringio", "~> 3.0"
101119
eval_gemfile "modular/style.gemfile"

kettle-test.gemspec

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,10 @@ Gem::Specification.new do |spec|
140140
spec.add_development_dependency("stone_checksums", "~> 1.0") # ruby >= 2.2.0
141141

142142
# Development tasks
143-
spec.add_development_dependency("erb", ">= 2.2") # ruby >= 2.3.0, not SemVer, old rubies get dropped in a patch.
143+
# The cake is a lie. erb v2.2, the oldest release on RubyGems.org, was never compatible with Ruby 2.3.
144+
# This means we have no choice but to use the erb that shipped with Ruby 2.3
145+
# /opt/hostedtoolcache/Ruby/2.3.8/x64/lib/ruby/gems/2.3.0/gems/erb-2.2.2/lib/erb.rb:670:in `prepare_trim_mode': undefined method `match?' for "-":String (NoMethodError)
146+
# spec.add_development_dependency("erb", ">= 2.2") # ruby >= 2.3.0, not SemVer, old rubies get dropped in a patch.
144147
spec.add_development_dependency("gitmoji-regex", "~> 1.0", ">= 1.0.3") # ruby >= 2.3.0
145148
spec.add_development_dependency("rake", "~> 13.0") # ruby >= 2.2.0
146149
end

0 commit comments

Comments
 (0)