Repository navigation
feat(harness): declarative node config — set up ESP32 CSI nodes from one YAML file - #2545
matthewxfz3 wants to merge 8 commits into
Conversation
Replaces the per-board esptool/provision.py chain with a declarative config applied by MAC. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
proffesor-for-testing
left a comment
There was a problem hiding this comment.
REMAND at 59cb729. Existing targeted tests pass (28/28), but three independent synthetic production-function probes expose gaps. No real serial ports, UDP listeners or devices were opened; author branch unchanged.
-
P1 — bind interactive confirmation to the displayed board/plan. EXECUTED.
harness/ruview/src/cli.js:289-299obtains an unconfirmed plan, asks permission for its MAC/node, then callsapplyBoardagain without the expected MAC/plan.node-config.js:522re-probes and adopts whatever board now occupies the path. Probe: plan MAC A/node1; replace mocked MAC with B/node2 on the same port before the confirmed call; the provisioning mock receives--node-id 2and the result isok:true. Re-identification is necessary, but a changed identity must invalidate the old confirmation. Pass an immutable expected MAC/node/plan into confirmed execution and reject mismatch before flash, registry assignment or NVS writes; test replacement between plan and confirmation. -
P1 — registry restoration can duplicate an explicitly configured node ID. EXECUTED.
harness/ruview/src/node-config.js:332-333restores the last registry ID without checking current assignments. Probe: registry MAC B has node4; YAML now assigns node4 to different MAC A;resolveNode(config, B, registry)returns B/node4, sourceregistry. Applying both boards produces the same stream identity. Reject/reconcile conflicting restored IDs against the full current config and active registry map before planning or writes; add stale-registry versus explicit-config collision controls. -
P2 — offline auto-assigned nodes disappear from status and can yield false success. EXECUTED.
harness/ruview/src/node-config.js:610-614builds registry assignments but omits their IDs from the iteration set. Probe: empty YAML node list, registrynode_assignedMAC B/node4, empty mocked capture.nodeStatusreturnsok:true,nodes:[],0/0 known nodes healthy. Include active known registry IDs in status and retain an offline/no-CSI row; test disappearance/reappearance independently of explicit YAML entries.
Applicability to the managed Mac/radar lane: this is a generic CSI CLI, not a dedicated MR60 installer. Its example aggregator UDP5005 must not be copied into the current raw55063/radar5005 split without explicit configuration. Status also competes for the live receiver port; no live status/apply qualification was attempted. No C5, signed-app, USB replacement or physical radar acceptance claim is made.
Verification: frozen Git archive of this head, including its exact YAML example; node --test --test-reporter=dot test/node-config.test.mjs test/firmware.test.mjs PASS28. Separate Node imports of production normalizeNodeConfig, resolveNode, nodeStatus, applyBoard used temporary synthetic registry/config and mocked exec/capture/fetch to reproduce the findings above. Full package suite and hardware checks were not rerun.
proffesor-for-testing
left a comment
There was a problem hiding this comment.
NO BLOCK for the three repaired review findings at 3e1af4f. This is the repair author's bounded recheck, not an independent or formal human approval.
EXECUTED: eleven new regressions; eight fail on frozen original59cb and all pass on the repair. Focused39/39; full package314pass/5existing skips/0fail with canonical TMPDIR; original default-temp hosts failures independently reproduced. Manifest65-file integrity, Gitleaks and diff checks pass. Checked the actual CLI caller passes displayed MAC/node into confirmed execution before any registry/device writes; covered same-board assignment drift, registry/config and registry/registry collisions, explicit reassignment, malformed records, offline→online status and ambiguous identity reporting.
The original REMAND remains an accurate historical verdict for59cb; its three findings are closed at this new head. CI status and original hardware/receiver qualification limits remain separate; no physical operation or merge.
proffesor-for-testing
left a comment
There was a problem hiding this comment.
NO BLOCK within the repaired findings/current-main reconciliation scope at b02ef79. Repair-author recheck; not an independent or formal human approval.
The three original findings are closed: displayed MAC/node binds confirmation before side effects; effective retained/config ownership rejects collisions; offline registry nodes remain visible/unhealthy and ambiguous IDs are explicit. Eleven new regressions include eight original-source failures and three compatibility controls. Final reconciled head:41focused PASS; full package318PASS/5existing skips/0FAIL with canonical TMPDIR; manifest65-file integrity, Gitleaks and diff checks PASS.
Normal merge of main094 resolves the original PR's existing conflicts, preserves upstream strict CSI callback evidence/C5 watchdog/security-eFuse/flash-capacity protections and package0.9.3 bounded test concurrency. GitHub mergeable=true. Hosted checks/runs are not reported yet; no hosted-CI pass or physical qualification is inferred. Main and installed app/helper/devices were not changed. Earlier reviews remain historical for their exact heads.
…d board's ID plan resolved against an empty registry, so it passed configs apply then refused, and a gone board's ID could only be freed by hand-editing devices.jsonl. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks for the review and the repair commits. Follow-up at 578ca7b for two gaps in the new node-ID conflict logic:
Also:
The 5 new regressions fail on b02ef79's One question on the |
|
NO BLOCK in the reviewed node-ID conflict/retirement delta at578ca7b2232a6e20441717b9bfd25d2c738dd3a3. EXECUTED:45 focused node-config/firmware tests passed; the complete harness run passed322 tests with5 skips after installing the pinned development dependencies and using canonical /private/tmp for macOS fixtures. The first full run lacked @metaharness/flywheel and hit existing /var versus /private/var fixture assumptions; those were environment/portability failures, not changes to this PR. No source changes were needed for this review. STATIC: plan now resolves against the same registry as apply; retired MACs release their retained IDs and are refused if selected again; normalized config prevents active/retired overlap; offline inventory excludes retired entries. The updated boot-banner expression still recognizes the current S3 banner. Explicit confirmation, MAC re-probe and firmware identity checks remain. No hardware, USB, flashing, Wi-Fi or live CSI acceptance performed. Hosted checks are not reported for this head. This is a scoped software review, not merge authorization or hardware qualification. |
|
Current-head CI/review reconciliation at
Next steps: approve the intended workflow executions through the repository's normal process, obtain current-head results, and refresh the maintainer review on578ca7b (or its replacement). No workflow approval, source edit, merge or device action performed in this reconciliation. |
|
CI/review reconciliation at unchanged head The old PR-event CI checks out Two newly executed failures remain actionable:
The dedicated device-e2e workflow, CSI policy and fix-marker runs passed. These are source/test checks, not physical hardware qualification. The prior code-only NO BLOCK does not mean current CI is green; formal approvals on |
|
Current-main candidate qualification completed on
The separate npm package-size and Windows assertion failures above remain open. The qualification branch's push filters do not execute those same PR-only package/flywheel jobs, so its green full CI cannot clear them. Contributor branch and reviewed size ceiling remain unchanged; no main merge/release was performed. |
Run the MQTT test broker from the eclipse-mosquitto:2.0.18 image, build Espressif QEMU on ubuntu-24.04, and enable git long paths before cargo on Windows. Plan item 0.6. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T8hca9bTB4puaeBstXR9CE
|
Taking the remaining CI repairs under Dragan's selected server lane. Current contributor head578ca7b2232a6e20441717b9bfd25d2c738dd3a3 is preserved; please flag conflicting source/workflow edits. Planned normal update in an isolated worktree: incorporate current-main and #2583's shared runner repairs without a main merge; correct the existing Windows tilde-expansion test to native path semantics; propose an explicit480KiB package ceiling for the new node-config capability. Local npm pack reproduces479863bytes (468.6KiB), including44024bytes for the new runtime module; the old448KiB ceiling predates that capability. The proposed480KiB ceiling retains a hard bound with11657bytes headroom. This is an explicit feature-footprint change for review, not a claim that the old ceiling passed or an already-approved policy. Runtime node-config behavior, device-ID conflict/retirement guards and security manifests remain unchanged. Preserve full package, harness, Windows, broker/QEMU/fuzz qualification; no device flashing, contributor-history rewrite, main merge or release. Will provide new exact head, pack inventory, tests and fresh CI before treating ready. Owner Dragan; agent Codex; host DraganMac; session ruview-server-repairs-20261119; lease until14:25UTC. |
Current CI repair — 2026-11-19
Current head
73640844e0b8acff47c9a75bb5d9a7b6cf9794a9incorporates main13b4788 and runner PR #2583 at6bff4df9 through a normal history-preserving merge. Land/reconcile #2583 first; no server main merge or release occurred here.path.joinsemantics; runtime node configuration and device-ID conflict/retirement guards are unchanged.The original feature description and contributor's earlier hardware evidence below are preserved as historical context.
Summary
Bringing up an ESP32 node today means a manual chain per board: pick the image, run esptool, run
provision.pywith the right node ID, TDM slot and target, then check the stream. This PR makes setup config-driven. One YAML file (~/.ruview/nodes.yaml) declares the network, aggregator, firmware and every node by MAC.ruview node applybrings an attached board to that declared state, reusing the existing pieces:flashFirmware,provision.pyand the UDP capture.ruview node plan: validate the config and show what each node will get. Read-only.ruview node apply: read the board's MAC, resolve its node (config, then registry, then next free ID), and run the configured steps: flash → provision → validate.--firmware-onlyflashes and validates while keeping the settings. Works with--port,--allor--watch.ruview node status: read-only per-node CSI rate, loss and RSSI from UDP, joined with:8032/ota/status.yes, or--confirm. Without a terminal (pipes,--json, MCP), only the plan is printed.provision.py, so the harness never reads them. Inline passwords and env-var sources are refused.addresssummarizeBootLogparses the currentCSI Node … — vX.Y.ZbannerTemplate:
firmware/esp32-csi-node/nodes.example.yaml.Test plan
Hardware: two ESP32-S3 boards (QFN56 rev v0.2, 16 MB flash, 8 MB PSRAM, WCH CH343), macOS 15, firmware 0.8.15 from a local
build/with the DevKitC overlay. MACs, IPs, SSID and paths are redacted.Unit tests
Package tests. Both failures also fail on
mainon macOS, from/varvs/private/vartmpdir comparisons in the hosts tests:Plan from a real config (read-only):
Apply, prompt declined: nothing is written (registry unchanged):
New, unlisted board, full apply. MEASURED; reproduce with
ruview node apply, validate stage plus boot log. Captured just before the command rename (fleet→node); the code path is unchanged:Registry trail for that board (no secrets):
Read-only status (MEASURED; reproduce with
ruview node status; node 1 was unplugged):Firmware-only on both boards. The flash succeeds and the version parses. Validation reports the UDP port held by another receiver (see follow-ups):
Follow-ups
--firmware-onlyshould honoursteps.ruview esp32 --seconds 15): both nodes show 34–37% CSI sequence loss on channel 11.validate.max_lossexists but is unset by default.🤖 Generated with Claude Code
Maintainer follow-up — 2026-11-13
At Dragan's request, repair
3e1af4f9fixes the three findings in review 5888074936. Final headb02ef79ad1be51042da985cfe686e36d4bbc88a7also reconciles current main094e1400via a normal merge commit; pre-existing conflicts are resolved, upstream C5 safeguards/package0.9.3/test concurrency are preserved, and generated manifests are rebuilt.id-conflict.Eleven regressions were added: eight fail on original59cb and pass on repair; three positive/compatibility controls remain passing. Final reconciled validation on Node24.19.0/macOS: 41 focused tests pass; full package318pass/5existing skips/0fail with
TMPDIR=/private/tmp. The two default macOS temp-path alias hosts-test failures were reproduced on original and repaired source; canonical TMPDIR runs the full suite without exclusions. Harness65-file manifest verification, Gitleaks and whitespace checks pass. GitHub reportsmergeable:true; no hosted checks/workflow runs are reported for this head yet, so hosted CI is not claimed green. No real USB/UDP, firmware/app/device operation or main merge was performed.