gocardless / statesman

A statesmanlike state machine library.
https://gocardless.com/blog/statesman/
MIT License
1.78k stars 163 forks source link

Silence the deprecation warnings introduced in Rails 7.1 #517

Closed freesteph closed 1 year ago

freesteph commented 1 year ago

DEPRECATION WARNING: Passing the coder as positional argument is deprecated and will be removed in Rails 7.2.

Please pass the coder as a keyword argument:

serialize :metadata, coder: JSON

freesteph commented 1 year ago

@ivgiuliani any chance you can glance over this? Thank you!

ivgiuliani commented 1 year ago

I had a quick look this morning, this might not be as easy -- we still support rails 6.1 as per our compatibility policy but from a quick glance at the docs it looks like the coder keyword argument doesn't work for that version. I'll try to test this later but we might need to be a bit more clever here somehow

freesteph commented 1 year ago

Thanks @ivgiuliani ! Closing in favour of https://github.com/gocardless/statesman/pull/520.