Skip to content

Navigation Menu

Sign in
Sign up

State Machine diagram to display all visited states #467

iseletsk started this conversation in Ideas
Discussion options

I love the library, and the diagrams make it so easy and useful to think about 'what is happening' and 'how did I get here.'
It would be great to mark each state that has visited so far in a separate color.
This way I can generate a diagram once I got to the final state, and have a pretty good idea on all that states that I visited/how I got there.

You must be logged in to vote

Replies: 1 comment 1 reply

Comment options

Hi @iseletsk , thanks for getting in touch and also for your kind words :)

I liked the idea and think we may implement it in the library. For now, If you just want to make it happen in a "hackish form", I can think It can be done subclassing the statemachine.contrib.diagram.DotGraphMachine overriding the _state_as_node method, and registering a custom listener that tracks the visited states.

Please let me know if you need help implementing this.

You must be logged in to vote
1 reply
Comment options

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Ideas
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /