Repository navigation
The first patch release since 0.12.0: faster sync event delivery, a much faster FileStore lock under on-access antivirus, a fixed xsm console, a docs site that draws its own diagrams, and a benchmark refreshed against the latest competitor releases.
Highlights
SyncInterpreter.send()does about half the Python calls per event on a guarded self-transition (66 → 32 under cProfile). On the cross-library benchmark the guard + action row is now 1.63× ahead oftransitions. Semantics unchanged, pinned bytests/test_sync_send_fast_paths.py.FileStorestops rewriting its lock-file holder stamp when it is fresh. A lock cycle under Defender dropped from 9.9 ms to 0.18 ms;savewithfsyncoff went from 26 ms to 10 ms. The OS lock remains the truth.- The
xsmconsole resolvessys.stdoutand its styling per write. Hosts that redirect output no longer hitValueError: I/O operation on closed file, and a swap to a file or pipe stops emitting ANSI and box glyphs. - The docs site draws its own diagrams. Stately's embedded editor now requires sign-in, so all 245 charts are generated from each machine's JSON and rendered with Mermaid 12 (ELK), in the Stately notation and palette, every chart keeping its Open in Stately link. Colours follow the theme in every diagram type, and no chart is drawn below 75% of its natural size — wide charts scroll instead of shrinking labels to a few pixels.
- Benchmark refreshed against the latest releases — transitions 0.9.3, python-statemachine 3.2.2, sismic 1.6.14 — in three quiet sessions; six of eight rows stay ours, the statechart rows 4.8–5.2× the next library.
Also fixed
- Three CI flakes removed at their roots: the stalled-SSE bound in the EDA example, the FileStore thread smoke, and the concurrent dead-letter test (which now surfaces worker errors and waits for them).
- README and landing-page claims corrected in a pre-release review (quickstart status comment, RedisStore import hint, the Stately sign-in note, the Python-block coverage claim, and the runnable-example count, now pinned by a test).
Install
pip install --upgrade xstate-statemachine==0.12.1Full notes: https://basiltt.github.io/xstate-statemachine/guide/changelog/#0121---2026-11-07