Repository navigation
Support Mongoid 9 and Rails 8.1 (3.1.0) - #178
Merged
Merged
Conversation
Allow mongoid < 10 and require ransack-mongoid 1.1, which adds Mongoid 9 support. The test app gets a Mongoid 9 config, and CI adds Rails 7.2 and 8.0 on Mongoid 9.0 and Rails 8.1 on Mongoid 9.1 (Rails 8.1 needs Mongoid 9).
boie0025
approved these changes
Dec 2, 2026
boie0025
left a comment
Member
There was a problem hiding this comment.
Approving, on the condition you already gave: drop 148454c (the TEMPORARY ransack-mongoid branch pin in the Gemfile) once ransack-mongoid 1.1.0 is on RubyGems, and re-run CI against the released gem before merging. Otherwise master's Gemfile would point at a branch that's about to be deleted.
The rest looks good:
mongoid < 10andransack-mongoid ~> 1.1go together. Requiring 1.1 means Bundler can't pair Mongoid 9 with ransack-mongoid 1.0, which caps Mongoid below 9.- The CSV export's query-cache fallback is still safe on Mongoid 9.
Mongoid::QueryCachewas removed there, but Mongoid 9 requires a driver that hasMongo::QueryCache, so thedefined?check always picks the driver's.
Two small things, neither blocking:
- The gemspec now allows Mongoid 9 on Rails 7.0 and 7.1, but the matrix only runs Mongoid 9 on Rails 7.2, 8.0 and 8.1. Either add a
{ rails: '7.1', mongoid: '9.0' }row or say in the README that Mongoid 9 is tested from Rails 7.2. - The README requirement "Mongoid 9 needs activeadmin-mongoid 3.1" is a bit circular in a section headed "Requirements for version 3.x". Something like "Mongoid 9 needs 3.1 or later" would read more clearly.
The gemspec allows Mongoid 9 with Rails 7.1, so CI tests that pair too.
jdguzman
force-pushed
the
jd/mongoid-9
branch
from
December 2, 2026 20:24
3abc38d to
924dc5e
Compare
Member
Author
|
Thanks. ransack-mongoid 1.1.0 is on RubyGems, so the condition is met:
The branch now has three commits:
|
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.
Adds Mongoid 9 and Rails 8.1 support, released as 3.1.0.
No library changes were needed. The adapter passes unchanged on Mongoid 9.0 and 9.1.
mongoidis now>= 7.5, < 10, andransack-mongoidis~> 1.1. ransack-mongoid 1.1 adds Mongoid 9 support (Support Mongoid 9 (1.1.0) riverock/ransack-mongoid#5).config/mongoid.9.yml.Run locally, all 31 examples pass on Rails 8.1 + Mongoid 9.1 (Ruby 3.2, 3.3, 3.4 and 4.0), Rails 8.0 + Mongoid 9.0, and Rails 7.2 + Mongoid 9.0 (Ruby 3.1 and 3.4). They also pass on spot checks of the existing rows.
The 3.0.1 follow-ups (#175, #176, #177) aren't included.