Closed MHP47 closed 4 years ago
Hello @MHP47,
this might look a bit confusing but when you trigger a new event while entering a state, the event will be processed at this point. The message "Entered state queued=True
in the Machine
constructor.
First off, great library!
Was tracking down an issue in some code, and couldn't work out what/why was happening. Reason being, the debug logging was actually more confusing than helpful.
Demo code:
and this prints:
Which is as expected, transitioning from 1 to 2, then to 3, but then it prints going back to 2. Going off the logging, the state should be 2, but it's clearly 3. The logic seems to work, but the logging catches the walk back up the stack