Skip to content

Commit c00279f

Browse files
committed
Limit beaker-puppet to older Rubies
No version of beaker-puppet is compatible with Ruby >= 3.2 because of taint functions. Because beaker-puppet specifies that it cannot run on Ruby > 3.1 in its gemspec, when you run bundle install on newer Rubies-even when excluding the Gem group to which beaker-puppet belongs-Bundler errors. This commit updates the Gemfile to only list beaker-puppet if Ruby is less than 3.1.0.
1 parent f3e0eca commit c00279f

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

.sync.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,11 @@ Gemfile:
2424
from_env: BEAKER_HOSTGENERATOR_VERSION
2525
- gem: beaker-rspec
2626
from_env: BEAKER_RSPEC_VERSION
27+
# Prevent beaker-puppet from being installed on Ruby > 3.1 until beaker-puppet supports newer Rubies (PA-6136)
2728
- gem: beaker-puppet
2829
from_env: BEAKER_PUPPET_VERSION
2930
version: '~> 3.0'
31+
condition: Gem::Requirement.create('< 3.2.0').satisfied_by?(Gem::Version.new(RUBY_VERSION.dup))
3032
# We can unpin async when we move to Ruby 3
3133
- gem: async
3234
version: '~> 1'

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ group :development do
4040
gem "beaker-abs", *location_for(ENV['BEAKER_ABS_VERSION'] || '~> 1.0')
4141
gem "beaker-hostgenerator"
4242
gem "beaker-rspec"
43-
gem "beaker-puppet", *location_for(ENV['BEAKER_PUPPET_VERSION'] || '~> 3.0')
43+
gem "beaker-puppet", *location_for(ENV['BEAKER_PUPPET_VERSION'] || '~> 3.0') if Gem::Requirement.create('< 3.2.0').satisfied_by?(Gem::Version.new(RUBY_VERSION.dup))
4444
gem "async", '~> 1', require: false
4545
gem "beaker-module_install_helper", require: false
4646
gem "beaker-puppet_install_helper", require: false

0 commit comments

Comments
 (0)