Questions tagged [pytransitions]

Transitions is a lightweight, object-oriented state machine implementation in Python with many extensions.

Transitions is a flexible state machine library compatible with Python 2.7+ and Python 3+. It features extensions such as hierarchical/nested states, state diagrams, state decorators (e.g. Error states or Timeouts), thread-safe and asynchronous machines.

Resources

49 questions
0
votes
1 answer

How to delegate listening to entering states of a `transitions` state machine?

I am trying to use the transitions library. This question follows this one, quite loosely. I would like to delegate listening to on_enter events to all states and create several such listeners that can subscribe and be notified when entering a…
Gulzar
  • 23,452
  • 27
  • 113
  • 201
0
votes
1 answer

Correct way of using AsyncMachine and multiple objects in transitions

i'm trying to implement client-server application via websockets and i have several doubts how to do it correctly to maintain state of every connected client. global machine + many objects for each connection? machine + object - for each…
Eugene
  • 19
  • 1
0
votes
1 answer

Model already contains an attribute 'trigger'. Skip binding

I want to implement state machine for my Order model, and I am using this beautiful pytransitions library. But I am facing this strange issue. This is my order.py with model: from order_state_machine import OrderStateMachine class…
Eziz Durdyyev
  • 1,110
  • 2
  • 16
  • 34
-1
votes
1 answer

Is the internal transitions of pytransitions working

I'm trying to use the internal transitions feature of pytransitions version 0.6.4 but it is not working for me. I get an error File "/python3.6/site-packages/transitions/core.py", line 720, in set_state mod.state = state.name AttributeError:…
1 2 3
4