use supported version of gem state_machine
I did some looking around, and here are my notes so far: The current version we are using is the specific git commit https://github.com/seuros/state_machine/commit/95ba53f03e5657a5873343c2b1dc6a148ea3542e The arooo commit message is "Switch to less abanadoned version of state_machine gem - But this is only a step toward actually being on the maintained version, but can't do that till we get on Rails 4.2"
I read the thread on https://github.com/pluginaweek/state_machine/issues/310 (the original, now unmaintained gem) and it sounds like https://github.com/state-machines/state_machines (maintained by sauros) is the current most maintained fork. I tried all the versions published at https://rubygems.org/gems/state_machines/versions but I get the error ERROR: null value in column "state" violates not-null constraint in all our tests.
I'm not yet confident whether this is a real problem or just a problem with test setup- in order to figure this out I'll
- start up the server and do some manual testing locally
- check the data in prod to make sure we don't have null
statuscolumn values
There are no users with empty state in prod
Loading production environment (Rails 4.2.11.1)
irb(main):001:0> User.where(state: nil)
=> #<ActiveRecord::Relation []>