code wiki / (root) / nx_iot_scene_sync_test.nx

nx_iot_scene_sync_test.nx

buildroot/runtime/nx_iot_scene_sync_test.nx

6665 B119 linesdepth 3pulls 4 transitivereach 0 importersview sourcekind gate/prooftopic iot
docsdependenciesstructsconstsfunctions

about

nx_iot_scene_sync_test.nx -- gate for the lights-stay-in-sync organ. Proves the operator's "repeatable self-fixing" sync as PURE LOGIC: - sealed-enum validity - init + set_scene establishes a single source of truth (epoch bumps) - new devices start OUT of sync; resync_all converges the whole fleet - all_in_sync flips correctly; count_desynced is exact - DROP+HEAL: a device marked desynced is out of sync, then resync pulls it back -- and REPEATING the drop+heal re-fixes it every time - MEASURED syncs_restored / desyncs_seen grow with each cycle - a SCENE CHANGE knocks the whole fleet out of sync (new epoch) until re-applied -- the room re-syncs as one - idempotent add (#10); not-found / bad-arg guards expect_exit: 0 license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_syscalls_x86_64.nx nx_iot_scene_sync.nx nx_iot_scene_sync_test.nx

imports: nx_syscalls_x86_64.nxnx_iot_scene_sync.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main nx_iot_sync_verdict_is_val nx_iot_scene_init nx_iot_scene_epoch nx_iot_scene_count nx_iot_scene_all_in_sync nx_iot_sync_dev_epoch nx_iot_scene_set nx_iot_scene_get_brightnes nx_iot_scene_get_on nx_iot_scene_add_device nx_iot_sync_find nx_iot_sync_dev_lid nx_iot_scene_count_desynce nx_iot_sync_dev_epoch ↻ nx_iot_scene_needs_resync nx_iot_sync_find ↻ nx_iot_sync_dev_epoch ↻ nx_iot_scene_in_sync nx_iot_sync_find ↻ nx_iot_sync_dev_epoch ↻ nx_iot_scene_resync_all nx_iot_sync_dev_epoch ↻ nx_iot_scene_syncs_restore nx_iot_scene_mark_desynced nx_iot_sync_find ↻ nx_iot_scene_desyncs_seen nx_iot_scene_resync nx_iot_sync_find ↻ nx_iot_sync_dev_epoch ↻ nx_iot_scene_mark_applied nx_iot_sync_find ↻

structs

none

consts

none

functions

22func main() -> i64