Repository navigation
build: keep json below 3 for Rails 7 appraisals - #151
Merged
Merged
Conversation
json 3 no longer accepts the `quirks_mode` option that ActiveSupport 7.1 and 7.2 pass to `JSON.generate`, so every Rails 7 job failed with `ArgumentError: unknown keyword: quirks_mode`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
santiagorodriguez96
approved these changes
Sep 25, 2026
| appraise "rails-7_2" do | ||
| gem "rails", "~> 7.2.x" | ||
|
|
||
| # ActiveSupport 7.x passes `quirks_mode` to JSON.generate, which json 3 rejects. |
Collaborator
There was a problem hiding this comment.
What do you think about pointing to rails/rails#58685 instead? Although that issues is for Rails 8...
Contributor
Author
There was a problem hiding this comment.
That issue is ActiveSupport 8.1 passing a positional hash to JSON.parse, fixed in rails/rails#58601 for 8.1 only. Ours is 7.x passing quirks_mode to JSON.generate, which no Rails issue tracks. The common cause is in json 3.0's changelog: unknown options now raise ArgumentError.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What: Pins
jsonbelow 3 in therails-7_1andrails-7_2appraisals, and indevise-5_0on Ruby below 3.2, where it resolves Rails 7.Why: json 3.0 rejects the
quirks_modeoption that ActiveSupport 7.1 and 7.2 pass toJSON.generate. Every Rails 7 job fails withArgumentError: unknown keyword: quirks_mode, as in this run.masterwill fail the same way on its next run.How to test: CI is green.