Skip to content

Allow using json >= 3 by not calling JSON.fast_generate - #1468

Open
ahx wants to merge 2 commits into
prettier:mainfrom
ahx:allowjson-3
Open

ahx wants to merge 2 commits into
prettier:mainfrom
ahx:allowjson-3

Conversation

@ahx

@ahx ahx commented Sep 10, 2026

Copy link
Copy Markdown

JSON.fast_generate was removed in version 3. It's no longer faster.

Solves #1467

JSON.fast_generate was removed in version 3. It's no longer faster.
@ahx

ahx commented Sep 11, 2026

Copy link
Copy Markdown
Author

Do you understand why CI failing? I don't.

@ahx

ahx commented Sep 11, 2026

Copy link
Copy Markdown
Author

The failing seems to be related to changes between rbs 3 and 4.

UPDATE: I have updated the fixtures to what rbs 4 expects. Seems to work with rbs 3 as well.

@ahx
ahx requested a review from kddnewton September 11, 2026 14:41
@ahx

ahx commented Sep 16, 2026

Copy link
Copy Markdown
Author

Hey, @kddnewton. This gem is a central piece of our current pipeline. Having this change would allow us to change from json 2 to 3 in the whole org (https://github.com/ivx). Saying this to tell you that your work is used everyday and is a valuable piece of our system. Thanks for the work. So we are very happy if you find the time to look at this again, but no hurries.

brerx added a commit to ivx/ears that referenced this pull request Sep 18, 2026
Bump Ruby 4.0.6 -> 4.0.7, bundler to 4.0.21, gem dependencies (bunny,
rubocop, simplecov, etc). Pin json < 3 in the test group -- 3.0 removed
JSON.fast_generate, which @prettier/plugin-ruby's vendored server.rb
still calls; remove once prettier/plugin-ruby#1468 ships.

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants