Skip to content

Upgrade sequent to ruby 4#502

Merged
erikrozendaal merged 8 commits intomasterfrom
improvement/ruby-4-upgrade
Jan 29, 2026
Merged

Upgrade sequent to ruby 4#502
erikrozendaal merged 8 commits intomasterfrom
improvement/ruby-4-upgrade

Conversation

@sam-cw
Copy link
Copy Markdown
Contributor

@sam-cw sam-cw commented Jan 21, 2026

Since there don't seem to be any breaking changes we can still allow older ruby versions, so no need to increase the required ruby version.

Active record 8.1 has removed and changed the behaviour of type_cast and related methods that Sequent relies on in the postgres persistor, so I have added that restriction to the gemspec as well.

@sam-cw sam-cw requested a review from lvonk January 21, 2026 14:02
@sam-cw sam-cw force-pushed the improvement/ruby-4-upgrade branch 3 times, most recently from 567f584 to 82e52bb Compare January 21, 2026 15:26
@sam-cw sam-cw removed the request for review from lvonk January 21, 2026 15:29
@sam-cw sam-cw force-pushed the improvement/ruby-4-upgrade branch from 82e52bb to 63b3e64 Compare January 21, 2026 15:30
Since there don't seem to be any breaking changes we can still allow older ruby versions, so no need to increase the required ruby version.

Active record 8.1 has removed and changed the behaviour of type_cast and related methods that Sequent relies on in the postgres persistor, so I have added that restriction to the gemspec as well.
@sam-cw sam-cw force-pushed the improvement/ruby-4-upgrade branch from 63b3e64 to 501da64 Compare January 21, 2026 15:38
sam-cw and others added 7 commits January 21, 2026 17:12
Previously we relied on lookup_cast_type_from_column in the optimized postgres persistor, but that method has been deprecated without replacement.

Since we used that to get the logical value from the database we can instead ask the class for the active support type for the column in question, and then ask it to serialize the value - as I understand it this leads to an equivalent value as the prior approach which can then be type cast as before.
Resolve issues with active record 8.1 support
@erikrozendaal erikrozendaal merged commit 44bd626 into master Jan 29, 2026
6 checks passed
@erikrozendaal erikrozendaal deleted the improvement/ruby-4-upgrade branch January 29, 2026 14:29
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