Skip to content

Commit dbac19b

Browse files
committed
feat: SCXML processing model
1 parent 95d8289 commit dbac19b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+972
-437
lines changed

docs/processing_model.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,4 +77,3 @@ after 'connection_succeed' from 'connecting' to 'connected'
7777
```{note}
7878
Note that the events `connect` and `connection_succeed` are executed sequentially, and the `connect.after` runs on the expected order.
7979
```
80-

docs/transitions.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ Syntax:
8484
>>> draft = State("Draft")
8585

8686
>>> draft.to.itself()
87-
TransitionList([Transition(State('Draft', ...
87+
TransitionList([Transition('Draft', 'Draft', event='', internal=False)])
8888

8989
```
9090

@@ -101,7 +101,7 @@ Syntax:
101101
>>> draft = State("Draft")
102102

103103
>>> draft.to.itself(internal=True)
104-
TransitionList([Transition(State('Draft', ...
104+
TransitionList([Transition('Draft', 'Draft', event='', internal=True)])
105105

106106
```
107107

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,7 @@ select = [
170170
ignore = [
171171
"UP006", # `use-pep585-annotation` Requires Python3.9+
172172
"UP035", # `use-pep585-annotation` Requires Python3.9+
173+
"UP037", # `use-pep586-annotation` Requires Python3.9+
173174
"UP038", # `use-pep585-annotation` Requires Python3.9+
174175
]
175176

statemachine/engines/async_.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
from ..event_data import EventData
66
from ..event_data import TriggerData
77
from ..exceptions import TransitionNotAllowed
8-
from ..i18n import _
98
from .base import BaseEngine
109

1110
if TYPE_CHECKING:
@@ -46,7 +45,7 @@ async def processing_loop(self):
4645
first_result = self._sentinel
4746
try:
4847
# Execute the triggers in the queue in FIFO order until the queue is empty
49-
while self._running and not self.empty():
48+
while self.running and not self.empty():
5049
trigger_data = self.pop()
5150
current_time = time()
5251
if trigger_data.execution_time > current_time:

0 commit comments

Comments
 (0)