Re:Finite State Machines
by pknerd on Monday February 22, 2021 @09:12AM
(#26224722)
Anyone implemented in Python or Go for production systems?
[ Parent
| on HN ]
I've used https://github.com/pytransitions/transitions in production python systems.
It worked great but the system was fairly simple and wasn't changed often. In my opinion, it's nicer when the state machine can be defined as configuration (in XML or whatever) and then generate the code. Unfortunately that's not possible with vanilla pytransitions, but I suppose you could build a layer on top of it.
BTW, did you check this?
https://github.com/pytransitions/transitions/blob/master/exa...
I did not! I used it last a couple years ago, so maybe that's new. Thanks for sharing!
Interesting!
> Unfortunately that's not possible with vanilla pytransitions
Can you elaborate?
Re:Finite State Machines
by rad_gruchalski on Monday February 22, 2021 @05:30PM
(#26231560)
Protoactor for golang: https://github.com/AsynkronIT/protoactor-go#state-machines--....
Re:Finite State Machines
by davidkpiano on Monday February 22, 2021 @02:54PM
(#26229671)
I'm working on XState for Python: https://github.com/davidkpiano/xstate-python
Still a work-in-progress, but hope to make this production-ready this year.
x-state is easily the best js library for modelling state-machines on the front-end. the art is lost to many frontend engineers that UI is a series of states responding to inputs. so yeah, David thanks for your library.