From 2c97efdd9d147e8ef7725376289a87486a834905 Mon Sep 17 00:00:00 2001 From: Paul Thornthwaite Date: Tue, 12 May 2026 09:42:05 +0000 Subject: [PATCH 1/3] ci: Use bundler-cache instead of manual Bundler install Let ruby/setup-ruby manage Bundler and dependency installation. This avoids the manual Bundler install step and handles version differences more reliably. --- .github/workflows/ruby.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index aeae0283..52be84a9 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -32,9 +32,6 @@ jobs: uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby }} - - name: Install Bundler - run: gem install bundler -v $(grep -A 1 "BUNDLED WITH" Gemfile.lock | tail -n 1 | awk '{print $1}') - - name: Install dependencies - run: bundle install + bundler-cache: true - name: Run tests run: bundle exec rake From 80631e7c69c1d33d116f53f96b362c136002d358 Mon Sep 17 00:00:00 2001 From: Paul Thornthwaite Date: Tue, 12 May 2026 09:54:17 +0000 Subject: [PATCH 2/3] ci: Use "latest" Bundler with Ruby "head" Prevents picking up of the Gemfile's v2.4.22 which is no longer compatible with Ruby 4. --- .github/workflows/ruby.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index 52be84a9..7b3b7a87 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -26,6 +26,9 @@ jobs: DEBUG: "true" steps: - uses: actions/checkout@v3 + - name: Remove bundler version pin for head Ruby + if: matrix.ruby == 'head' + run: sed -i '/^BUNDLED WITH/{N;d}' Gemfile.lock - name: Set up Ruby ${{ matrix.ruby }} # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby, # change this to (see https://github.com/ruby/setup-ruby#versioning): From b5275d1b25d822f6299c098c4230e5ff581b0d62 Mon Sep 17 00:00:00 2001 From: Paul Thornthwaite Date: Tue, 12 May 2026 11:06:51 +0000 Subject: [PATCH 3/3] ci: Pin old Bundler for Ruby 2.7 and release others This inverts the dependency strategy and within the CI matrix allows everything to use the latest except for Ruby 2.7 which is known to fail with later Bundler versions. --- .github/workflows/ruby.yml | 7 ++++--- Gemfile.lock | 3 --- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index 7b3b7a87..8be58ad5 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -22,19 +22,20 @@ jobs: fail-fast: false matrix: ruby: ["2.7", "3.0", "3.1", "3.2", "3.3", "head"] + include: + - ruby: "2.7" + bundler: "2.4.22" env: DEBUG: "true" steps: - uses: actions/checkout@v3 - - name: Remove bundler version pin for head Ruby - if: matrix.ruby == 'head' - run: sed -i '/^BUNDLED WITH/{N;d}' Gemfile.lock - name: Set up Ruby ${{ matrix.ruby }} # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby, # change this to (see https://github.com/ruby/setup-ruby#versioning): uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby }} + bundler: ${{ matrix.bundler || 'default' }} bundler-cache: true - name: Run tests run: bundle exec rake diff --git a/Gemfile.lock b/Gemfile.lock index c00c75c0..5f1d8329 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -132,6 +132,3 @@ DEPENDENCIES simplecov vcr (~> 2.5) webmock - -BUNDLED WITH - 2.4.22