From 2680ab42a95a72f03f73e4e80a3b019406d5aadd Mon Sep 17 00:00:00 2001 From: Geremia Taglialatela Date: Thu, 24 Sep 2026 11:08:41 +0200 Subject: [PATCH] Pin json below 3.0 json 3.0 is incompatible with current Rails test setups until rails/rails#58601 makes it into a release. Pin below 3.0 in the Gemfile and appraisal gemfiles, and tell dependabot to skip >= 3.0.0. --- .github/dependabot.yml | 3 +++ Appraisals | 2 ++ Gemfile | 2 ++ gemfiles/csv_24.0.gemfile | 1 + gemfiles/csv_edge.gemfile | 11 ++++++----- gemfiles/mongoid_9.0.gemfile | 9 +++++---- gemfiles/mongoid_edge.gemfile | 11 ++++++----- 7 files changed, 25 insertions(+), 14 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index af2c121..1344e97 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -13,3 +13,6 @@ updates: cooldown: default-days: 5 open-pull-requests-limit: 10 + ignore: + - dependency-name: json + versions: ">= 3.0.0" # TODO: remove when a Rails release includes rails/rails#58601 diff --git a/Appraisals b/Appraisals index 216120b..e433ec5 100644 --- a/Appraisals +++ b/Appraisals @@ -1,5 +1,7 @@ # frozen_string_literal: true +gem 'json', '< 3.0' # TODO: relax this constraint when rails/rails#58601 will be released + appraise 'csv-24.0' do gem 'client_side_validations', '~> 24.0' end diff --git a/Gemfile b/Gemfile index 04a1623..792d5b1 100644 --- a/Gemfile +++ b/Gemfile @@ -4,6 +4,8 @@ source 'https://rubygems.org', cooldown: 5 gemspec +gem 'json', '< 3.0' # TODO: relax this constraint when rails/rails#58601 will be released + gem 'appraisal2' gem 'byebug' gem 'database_cleaner-mongoid' diff --git a/gemfiles/csv_24.0.gemfile b/gemfiles/csv_24.0.gemfile index 072a1d7..a6fa5c9 100644 --- a/gemfiles/csv_24.0.gemfile +++ b/gemfiles/csv_24.0.gemfile @@ -2,6 +2,7 @@ source "https://rubygems.org", :cooldown => 5 +gem "json", "< 3.0" gem "appraisal2" gem "byebug" gem "database_cleaner-mongoid" diff --git a/gemfiles/csv_edge.gemfile b/gemfiles/csv_edge.gemfile index b2dc991..bbb4e53 100644 --- a/gemfiles/csv_edge.gemfile +++ b/gemfiles/csv_edge.gemfile @@ -1,8 +1,9 @@ -# This file was generated by Appraisal +# This file was generated by Appraisal2 -source "https://rubygems.org" +source "https://rubygems.org", :cooldown => 5 -gem "appraisal" +gem "json", "< 3.0" +gem "appraisal2" gem "byebug" gem "database_cleaner-mongoid" gem "m" @@ -17,6 +18,6 @@ gem "rubocop-rails" gem "rubocop-rake" gem "simplecov" gem "sinatra" -gem "client_side_validations", git: "https://github.com/DavyJonesLocker/client_side_validations.git", branch: "main" +gem "client_side_validations", :git => "https://github.com/DavyJonesLocker/client_side_validations.git", :branch => "main" -gemspec path: "../" +gemspec :path => "../" diff --git a/gemfiles/mongoid_9.0.gemfile b/gemfiles/mongoid_9.0.gemfile index bc341a0..d66397d 100644 --- a/gemfiles/mongoid_9.0.gemfile +++ b/gemfiles/mongoid_9.0.gemfile @@ -1,8 +1,9 @@ -# This file was generated by Appraisal +# This file was generated by Appraisal2 -source "https://rubygems.org" +source "https://rubygems.org", :cooldown => 5 -gem "appraisal" +gem "json", "< 3.0" +gem "appraisal2" gem "byebug" gem "database_cleaner-mongoid" gem "m" @@ -19,4 +20,4 @@ gem "simplecov" gem "sinatra" gem "mongoid", "~> 9.0" -gemspec path: "../" +gemspec :path => "../" diff --git a/gemfiles/mongoid_edge.gemfile b/gemfiles/mongoid_edge.gemfile index a1cb43e..6e91f4a 100644 --- a/gemfiles/mongoid_edge.gemfile +++ b/gemfiles/mongoid_edge.gemfile @@ -1,8 +1,9 @@ -# This file was generated by Appraisal +# This file was generated by Appraisal2 -source "https://rubygems.org" +source "https://rubygems.org", :cooldown => 5 -gem "appraisal" +gem "json", "< 3.0" +gem "appraisal2" gem "byebug" gem "database_cleaner-mongoid" gem "m" @@ -17,6 +18,6 @@ gem "rubocop-rails" gem "rubocop-rake" gem "simplecov" gem "sinatra" -gem "mongoid", git: "https://github.com/mongodb/mongoid.git", branch: "master" +gem "mongoid", :git => "https://github.com/mongodb/mongoid.git", :branch => "master" -gemspec path: "../" +gemspec :path => "../"