Skip to content

v3.63.0 — correctness + resilience audit

Choose a tag to compare

@TaewoooPark TaewoooPark released this 26 Jul 19:41
· 3 commits to main since this release

A full-codebase audit against five criteria — stability, optimality, integrity, completeness, atomicity — run until two consecutive passes came back clean. 24 findings, every one reproduced before the fix and verified after. No behavior was changed except where it was wrong.

Correctness

  • Hover/focus was dead in every multi-page site clone. motionInteractionCss() emits .${PFX}uif-<i>:hover, but the componentized emitter pushed an unprefixed uif-<i> class. uiforge-site always exports with --prefix, so all interaction CSS matched nothing — and the class was also the cross-page collision the prefix exists to prevent. Reproduced against the previous build (.p0_uif-1:hover vs class="uif-1"), fixed, re-verified.
  • --prefix was missing from the positional-arg exclusion set, so --prefix X capture.json parsed X as the capture path.
  • docs/corpus/results.json was stale. Generated at v3.11.0 and never regenerated while the grader kept evolving, so the shipped "empirical validation" claimed numbers the code no longer produces (gradient.html F 57 / +52.3 pts; actual C 79 / +45). Confirmed the drift predates this audit, then regenerated.
  • Plugin manifests were eleven releases behind (3.51.0 vs v3.62.0), so an up-to-date install reported itself stale.

Stability

  • Unbounded fetch() in capture, freeze, and harvest — Node has no useful default timeout, and two of them Promise.all over every stylesheet, so one dead CDN set the floor for the whole run. All bounded now; verified against a server that accepts and never replies.
  • The archive replay server died on any missing file. The archive is documented as an editable mirror, so renaming a file killed the server outright — verified: one request took the process down and every later request got a dead connection. Now 404s and stays up; a busy port prints a retry hint instead of an uncaught EADDRINUSE.
  • uiforge-restore slept 1600 ms and hoped. A busy port surfaced much later as a misleading "could not extract a DOM". It now polls for readiness and reports the real cause.
  • Nine CLIs died with internal stacks when a positional argument was missing or swallowed as a flag value; uiforge-diff did so after launching Chromium, orphaning the browser. All exit cleanly now, and no browser survives a failure.

Security & performance

  • Path traversal in uiforge-visualgate's static server — /..%2Fsecret.txt returned a file from outside the served root (demonstrated). Paths are clamped inside the root, and both local servers now bind 127.0.0.1 instead of every interface.
  • The diff PNG crossed the CDP boundary as Array.from(buf) — a multi-million-element JS number array for a full-page diff, built and shipped even when --out wasn't passed. Now base64, and only on request.

Destructive-action safety

  • create-uiforge silently destroyed an existing pre-commit hook. husky and lint-staged live at exactly that path. It now leaves a foreign hook alone, is idempotent when the hook is already ours, and backs up to pre-commit.uiforge-bak under --force.
  • package.json was rewritten in place; now tmp + rename, atomic on POSIX.
  • uiforge-harvest ignored unknown flags, so a typo — or a reflexive --help — started a 419-request harvest that rewrites the committed catalog. It refuses now.
  • The committed catalog.db is checkpointed on every harvest, so recent rows can no longer live only in the gitignored -wal sidecar (2 MB was pending in the reproduction).

Completeness

  • commands/clone.md used $ROOT in eight snippets but only declared it in prose — run literally, every one became node /tools/…. Now an actual export. Three stale "Rebuild" references finished the rename to Restore.
  • The three catalog tools need Node ≥ 22.5 for node:sqlite and said so nowhere; they now exit 4 with the version you have, and the requirement is documented.
  • uiforge-corpus was the one tool documented nowhere — which is exactly how its numbers rotted unnoticed. It now has a section with the real table and a re-run instruction.
  • --help on uiforge-lint (absent) and create-uiforge (absent); uiforge-visualgate exited 1 for it.
  • Sizes under 1 KB printed as "0 KB" — a restored 295-byte stylesheet read as total failure.

Verified

Self-tests (render-audit, attention, extract) pass. Both pipelines run end-to-end: capture→theme→segment→export→reconstruct→diff (95.4% similar) and archive→replay→detect→restore. The corpus reproduces its committed results. All five token kits pass UIForge's own gate. 26/26 tools parse, --help works on all of them, and every tracked JSON file is valid.