Skip to content

GH Actions tests for Rails 7 #5111

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

johnnyshields
Copy link
Contributor

@johnnyshields johnnyshields commented Dec 28, 2021

This PR adds GH Actions tests supports for Rails 7.

Currently, this PR is blocked for Ruby 3.1 + Rails 7.0.0 support due to a last-minute change (hence I've disallowed 7.0.0 as a version.) This will be fixed in Rails 7.0.1. See rails/rails#43951.

@p-mongo
Copy link
Contributor

p-mongo commented Dec 28, 2021

Hi @johnnyshields , thank you for the PR.

As I mentioned in the bson-ruby PR, we will need to do a few things in order for ruby 3.1 to be testable in evergreen. If you extract the changes to yaml safe load etc. that don't deal with ruby or rails version into their own PR I think those can be merged right away.

@johnnyshields
Copy link
Contributor Author

YAML.safe_load changes here: #5112

@johnnyshields johnnyshields changed the title Support for Ruby 3.1 and Rails 7 Support for Rails 7 Dec 29, 2021
@johnnyshields johnnyshields changed the title Support for Rails 7 GH Actions tests for Rails 7 Dec 29, 2021
s.add_dependency("activemodel", [">=6.0", "<6.2"])
end
# activemodel 7.0.0 cannot be used due to Class#descendants issue (see: https://github.com/rails/rails/pull/43951)
s.add_dependency("activemodel", ['>=5.1', '<7.1', '!= 7.0.0'])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need a comment here saying that on Ruby 3 activemodel >= 6.0 is required to retain that note but the previous conditional that is being removed in this PR probably isn't valid in the gemspec, @comandeo do you agree?

Copy link
Contributor Author

@johnnyshields johnnyshields Dec 31, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rails 5.x does not support Ruby 3. This is not something specific to Mongoid, so I don't see why the Mongoid gem would need to add any comment or conditional logic here. See: rails/rails#40938

@AlexKovynev
Copy link
Contributor

it seems it can be merged now cause 7.0.1 is out https://twitter.com/rails/status/1479214221506322433

@johnnyshields
Copy link
Contributor Author

Specs are green! Let's merge @p-mongo

@p-mongo
Copy link
Contributor

p-mongo commented Jan 10, 2022

I folded this PR into #5122.

@p-mongo p-mongo closed this Jan 10, 2022
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.

4 participants