plan: two catalogue audits ask one question, and the ungated one is 33 devices wrong #1839

Merged
jaylouisw merged 1 commit from plan/1117-1210 into main 2026-11-17 12:16:29 +00:00
Owner

Forward plan only, no code: docs/plans/catalogue-audit-agreement.md.

Measured on 1855814a:

  • test/hardware-invariants.test.js gates "advertises optics without an optical cage" and asserts 0 (test/known-issues.json -> opticsWithoutCage: []).
  • scripts/audit-devices.js asks the same question with a hardcoded 5-entry OPTICAL_CAGES (:16) and no optional-module clause, and answers 33 � 28 PON (sc-apc/sc-upc), 3 Fibre Channel (fc-sfp*/fc-qsfp28), 2 optional-SFP prose.
  • engine/media.js:339 already classifies all of those cages (family: optical / fibre-channel); neither audit reads it.
  • Nothing invokes audit-devices � no npm script, no workflow � and it process.exit()s at import (:81), so no test can ask it anything.

Six S-sized steps: make the audit importable, pin the disagreement as a failing test, one isOpticalCage() predicate in engine/media.js (33 -> 2), strip the optional clause (2 -> 0), decide whether the audit runs in npm test or is deleted (delete = needs Jays approval), and let both audits verdict lines name what they gated versus what they merely reported.

Closes no open issue: the queue is seven device requests. Deliberately leaves out the 2,968 undeclared template ports (#71), the OTN media family (docs/plans/stated-configurations.md step 6), and stale counts in a test header.

Forward plan only, no code: `docs/plans/catalogue-audit-agreement.md`. Measured on `1855814a`: - `test/hardware-invariants.test.js` gates "advertises optics without an optical cage" and asserts **0** (`test/known-issues.json` -> `opticsWithoutCage: []`). - `scripts/audit-devices.js` asks the same question with a hardcoded 5-entry `OPTICAL_CAGES` (`:16`) and no optional-module clause, and answers **33** � 28 PON (`sc-apc`/`sc-upc`), 3 Fibre Channel (`fc-sfp*`/`fc-qsfp28`), 2 optional-SFP prose. - `engine/media.js:339` already classifies all of those cages (`family: optical` / `fibre-channel`); neither audit reads it. - Nothing invokes `audit-devices` � no npm script, no workflow � and it `process.exit()`s at import (`:81`), so no test can ask it anything. Six S-sized steps: make the audit importable, pin the disagreement as a failing test, one `isOpticalCage()` predicate in `engine/media.js` (33 -> 2), strip the optional clause (2 -> 0), decide whether the audit runs in `npm test` or is deleted (delete = needs Jays approval), and let both audits verdict lines name what they gated versus what they merely reported. Closes no open issue: the queue is seven device requests. Deliberately leaves out the 2,968 undeclared template ports (#71), the OTN media family (`docs/plans/stated-configurations.md` step 6), and stale counts in a test header.
plan: two audits ask one question, and the ungated one is 33 devices wrong
All checks were successful
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 7s
CI / Classify the change (pull_request) Successful in 10s
CI / Server smoke test (pull_request) Successful in 7s
CI / Docker build (pull_request) Successful in 23s
CI / Test (Node 20) (pull_request) Successful in 53s
CI / Test (Node 18) (pull_request) Successful in 1m2s
CI / Test (Node 22) (pull_request) Successful in 59s
CI / Arm auto-merge (pull_request) Successful in 15s
38866456ea
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jaylouisw/packetforge!1839
No description provided.