Skip to content
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

Rails 7 Support #2225

Merged
merged 9 commits into from
Apr 11, 2022
Merged

Rails 7 Support #2225

merged 9 commits into from
Apr 11, 2022

Conversation

tvdeyen
Copy link
Member

@tvdeyen tvdeyen commented Dec 30, 2021

What is this pull request for?

Adds support for Rails 7

Breaking changes

This removes support for eager loading ingredient_association from essence classes introduced in c45a6dd

Closes #2224

Need stable version from at least these gems

The list is very likely incomplete yet.

Checklist

@Paradoxor
Copy link

any update on the plans for releasing it?

But do not test Rails 7 with Ruby 2.6, because they dropped support for it.
Rails 7 does not autoload constants during boot anymore.
Now that the userclass will be set in a config.to_prepare
block in apps we need to run this code last.
@tvdeyen
Copy link
Member Author

tvdeyen commented Apr 11, 2022

any update on the plans for releasing it?

Nope. Sorry, "it's done when it's done"™️. If you want to help, please provide PRs against this branch.

@tvdeyen tvdeyen changed the title Rails 7 support Rails 7 Support Apr 11, 2022
To make this feature work we added a Hack into active record. This hack does not work in Rails 7 anymore.

Since contents with essences are deprecated anyway and we do not have this problem with ingredients it is not worth adjusting the hack to active record 7

This reverts commit c45a6dd
We need this until a Rails 7.0 version has been released to includes the fix for MySQL foreign keys

rails/rails#42350
This spec needs to be adopted to latest Rails versions.
This stopped working in Rails 7. Since Rails 5.2 it is possible to allow other hosts in redirect_to. Since this is a admin controller this is fine.
@tvdeyen tvdeyen marked this pull request as ready for review April 11, 2022 14:18
@tvdeyen tvdeyen added this to the 6.0 milestone Apr 11, 2022
Copy link
Contributor

@mamhoff mamhoff left a comment

Choose a reason for hiding this comment

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

LGTM!

@tvdeyen tvdeyen merged commit 26eacf8 into AlchemyCMS:main Apr 11, 2022
@tvdeyen tvdeyen deleted the rails-7 branch April 11, 2022 14:36
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.

Rails 7 support
3 participants