flybrain/services/flysim/crates
acamilo 3ea56ef3f8 tests: service_parity waits for the idle header instead of racing the pause
The idle-headers check failed 8 of 12 runs on a loaded build box (main
46e25ef: 3 of 4). The script paused and resumed 2 ms apart, so whether the
loop published a header-only idle snapshot in that window (due at 2 Hz) was
wall-clock luck, and legacy and session often disagreed. Not a product race:
the cadence is the protocol's.

The recorder now holds the resume until the first idle header has been seen
(bounded wait, 30 s), and the compare requires BOTH runtimes to have published
one, rather than merely agreeing on whether any did. The first idle header is
compared as before except for its `events` list: which publish carries the
pause's events is wall clock, and the events are compared in the running
snapshots and the event log.

Also fixed, found once the first was gone (1 in 20 under load): the two
sugars sent at one frame must be drained together; when the loop publishes
a snapshot while they are being sent the run is flagged incomplete and
repeated, like a missed frame.

What it proves, unchanged: a pause makes each runtime publish header-only
idle snapshots (status paused, no attachments) whose fields match the legacy
loop, and the script's responses, feed, event log, journal and final
checkpoint are identical between runtimes.

Under load (build box, load ~25 on 6 cores), toy_raw_service_contracts:
before 4/12 pass, after 40/40.
2026-10-02 01:12:56 +00:00
..
fly-edge fly-edge, flysim: a taken feed port is named as such; FLY_BUS_DIR must be absolute; worst case restated 2026-09-23 11:59:26 +00:00
fly-legacy-session tests: service_parity waits for the idle header instead of racing the pause 2026-10-02 01:12:56 +00:00
fly-session session: pin the sweep workers one per cpu in flysim-session (PERF-02) 2026-10-01 12:16:59 +00:00
fly-session-types session types: the legacy composition names pokered-unique8-v8 2026-09-30 02:11:45 +00:00
flybrain-core session: pin the sweep workers one per cpu in flysim-session (PERF-02) 2026-10-01 12:16:59 +00:00
flybrain-gb macros: the mart's list cursor is the entry too; the catch test pins its first-window ball (row 71) 2026-10-01 13:10:05 +00:00
flybus flybus: in-memory artifacts that never cross a router 2026-09-30 01:46:07 +00:00
flysim macros: the mart's list cursor is the entry too; the catch test pins its first-window ball (row 71) 2026-10-01 13:10:05 +00:00
flysim-store FLYSIM01 carries the reinforcement count; the import takes its ids from the file; StageRestore refuses conflicts before building a network 2026-09-29 17:17:56 +00:00