Skip to content

LBA REQ 015

github-actions[bot] edited this page Nov 19, 2026 · 2 revisions

LBA-REQ-015: VI Analyzer as a cross-plane benchmark

Status

Proven

Area

Analysis / quality (extends LBA-REQ-014; operator VI-Analyzer directive)

Statement

The system shall install the LabVIEW VI Analyzer Toolkit in the Windows clean room and summarize a VI Analyzer run over a repo's VIs into a deterministic, ORDER-INDEPENDENT result (per-run pass/fail/error counts + the enumerated per-VI findings + a resultHash), so a VI Analyzer run becomes a cross-plane-comparable benchmark: two planes summarizing the same run produce the same resultHash.

Rationale

Acceptance Criteria

  • The Windows docker clean room installs the VI Analyzer toolkit license (ni-labview-vi-analyzer-toolkit-lic) from the LabVIEW offline feed, enabling LabVIEWCLI -OperationName RunVIAnalyzer (cleanroom/docker-windows/install-vi-analyzer.ps1; Vagrant-reusable).
  • The REAL LabVIEWCLI RunVIAnalyzer report (ASCII/HTML) is FAILURE-ORIENTED: it emits a run summary of counts and enumerates ONLY the failures + testing errors per VI -- passes are never listed. So the normalized report is the faithful shape { config?, summary: { passed, failed, error, skipped?, unloadable? }, findings: [{ viPath, test, result: fail|error }] }; a clean all-pass run (e.g. the icon-editor CI gate) is the summary counts with an EMPTY findings array.
  • summarizeViAnalyzerReport() normalizes that report to { totalTests, passedTests, failedTests, errorTests, skippedTests, unloadableTests, totalFindings, findingsByVi, pass, resultHash }; the resultHash is deterministic, ORDER-INDEPENDENT, and LOCALE-INDEPENDENT (code-unit canonical order over the counts + sorted findings), so an identical report produces an identical resultHash on both planes. Consistency teeth: the fail/error findings counts MUST equal the summary failed/error counts.
  • A committed JSON Schema (vi-analyzer-report.schema.json) + a dependency-free validator (validate-vi-analyzer-report.mjs, the producing plane's pre-send self-check) lock the normalized-report input contract; a reference ASCII->v2 parser (parse-vi-analyzer-ascii.mjs) turns the real CLI report into it.
  • The summary projects to benchmark-store metrics (numeric counts + the resultHash digest), so crossPlaneCompare reports count deltas + the resultHash agreement (the resultHash MUST match cross-plane).
  • The REAL run is proven cross-plane by the CI OS matrix: the committed real report (experiments/vi-analyzer/icon-editor-report.json, WIN's attested all-pass icon-editor run) is pinned by local gate vi-analyzer-real-report-cross-plane-green, and the LBA Local Gates workflow runs on BOTH ubuntu-latest and windows-latest -- so both operating systems computing the same resultHash for the same real report IS the two-plane agreement.
  • The REAL run is ALSO proven cross-plane by two INDEPENDENT LIVE runs (the stronger form): the LINUX clean room (64-bit LabVIEW 2026 on Ubuntu/VBox) and the WIN clean room (32-bit LabVIEW 2026 on Windows/VBox) EACH ran LabVIEWCLI RunVIAnalyzer on the same shipped LabVIEWCLIExampleProject (3 VIs -> 69 tests) as a 6-run determinism trend, and both produced the byte-identical resultHash 0419a449... (compare-vi-analyzer-trend-cross-plane.mjs reports match=true, exiting 1 on mismatch). Timing legitimately differs (LINUX cold/warm 2.15x; WIN 19.34x -- Windows first-launch mass-compile/indexing), which the store crossPlaneCompare reports as numeric deltas while the resultHash digest matches. Receipts: vi-analyzer-trend-live-evidence.json (LINUX), vi-analyzer-trend-live-evidence-WIN.json (WIN), and vi-analyzer-trend-cross-plane-receipt.json; verify-vi-analyzer-trend.mjs re-derives every run's hash from committed data (no clean room needed to re-check).
  • Gated: verify-vi-analyzer-result (7/7), local gates vi-analyzer-result-model-green + vi-analyzer-report-schema-green + vi-analyzer-ascii-parser-green + vi-analyzer-real-report-cross-plane-green.

Verification

Historical statement (no longer implemented)

Supersession

Change Guidance

Keep summarizeViAnalyzerReport deterministic + order-independent + locale-independent (the cross-plane anchor is the resultHash; sort by code unit, never localeCompare). The normalized shape mirrors the tool's real failure-oriented output; do NOT reintroduce a per-test-pass enumeration the CLI cannot emit. Proven 2026-07-28 (operator-authorized): WIN ran the real LabVIEWCLI RunVIAnalyzer on the icon-editor VIs (452 passed / 0 failed, attested on the bus); the all-pass report experiments/vi-analyzer/icon-editor-report.json (resultHash df9c8d1e...) is proven cross-plane by the CI OS matrix (see the criterion above). WIN's independent re-commit from its Windows machine is welcome as corroboration.

TestID

T-015

CodeRef

experiments/vi-analyzer/viAnalyzerResult.mjs; experiments/vi-analyzer/verify-vi-analyzer-result.mjs; experiments/vi-analyzer/fixtures/sample-report.json; experiments/vi-analyzer/fixtures/sample-report-allpass.json; experiments/vi-analyzer/vi-analyzer-report.schema.json; experiments/vi-analyzer/validate-vi-analyzer-report.mjs; experiments/vi-analyzer/parse-vi-analyzer-ascii.mjs; experiments/vi-analyzer/icon-editor-report.json; cleanroom/docker-windows/install-vi-analyzer.ps1; experiments/vi-analyzer/vi-analyzer-live-evidence.json; experiments/vi-analyzer/vi-analyzer-trend-live-evidence.json; experiments/vi-analyzer/vi-analyzer-trend-live-evidence-WIN.json; experiments/vi-analyzer/run-vi-analyzer-trend.sh; experiments/vi-analyzer/run-vi-analyzer-trend.ps1; experiments/vi-analyzer/verify-vi-analyzer-trend.mjs; experiments/benchmark-store/compare-vi-analyzer-trend-cross-plane.mjs; experiments/benchmark-store/vi-analyzer-trend-cross-plane-receipt.json

RTM Status

Proven

Clone this wiki locally