While addressing review feedback on #3033, two independent drifts surfaced in docs/astryx-surface-file-inventory.{md,paths}, both from the same gap.
What is wrong
scripts/check-astryx-surface-inventory.mjs asserts that every product surface file on disk appears in the inventory. It never asserts the reverse. A row for a file that has been deleted survives the check indefinitely.
It is also not referenced from package.json or .github/workflows/ci.yml, so it does not run on its own. Nothing enforces the inventory at all today.
What that let through
Found on main as of 820a47b:
docs/astryx-surface-file-inventory.md carried rows for apps/desktop/src/renderer/external-session-import-dialog.tsx and apps/desktop/src/renderer/styles/external-session-import.css after both were deleted. The .paths half had been updated by hand; the Markdown half had not, so the two halves disagreed.
- Three files that arrived on
main were never listed in either half: apps/desktop/src/renderer/settings/runtime-host-profiles-section.tsx, apps/desktop/src/renderer/settings/runtime-host-ssh-terminal-dialog.tsx, and apps/desktop/src/renderer/styles/settings/runtime-host.css. This is the direction the check does cover — it simply was not running.
Both are corrected in #3033 (322a9ce) by running scripts/generate-astryx-surface-inventory.mjs rather than editing either half by hand. That fixes the current state, not the gap.
Proposed change
- Make
check-astryx-surface-inventory.mjs fail on inventory rows with no file on disk, in both .paths and the Markdown table, so the check is symmetric.
- Prefer asserting that the generator output matches the committed files byte-for-byte over re-implementing the comparison. These are generated artifacts; "regenerate and diff" is a stronger and simpler invariant than a list of hand-written rules, and it also catches column drift the current check ignores.
- Add an
npm script and wire it into the changes-gated CI path so it runs when surface files move.
The hand-editing is the root cause: a generated file maintained in halves drifts in whichever half the author forgets. A check that only runs one direction and only when someone remembers to run it cannot catch that.
Generated-by: Claude Code
While addressing review feedback on #3033, two independent drifts surfaced in
docs/astryx-surface-file-inventory.{md,paths}, both from the same gap.What is wrong
scripts/check-astryx-surface-inventory.mjsasserts that every product surface file on disk appears in the inventory. It never asserts the reverse. A row for a file that has been deleted survives the check indefinitely.It is also not referenced from
package.jsonor.github/workflows/ci.yml, so it does not run on its own. Nothing enforces the inventory at all today.What that let through
Found on
mainas of 820a47b:docs/astryx-surface-file-inventory.mdcarried rows forapps/desktop/src/renderer/external-session-import-dialog.tsxandapps/desktop/src/renderer/styles/external-session-import.cssafter both were deleted. The.pathshalf had been updated by hand; the Markdown half had not, so the two halves disagreed.mainwere never listed in either half:apps/desktop/src/renderer/settings/runtime-host-profiles-section.tsx,apps/desktop/src/renderer/settings/runtime-host-ssh-terminal-dialog.tsx, andapps/desktop/src/renderer/styles/settings/runtime-host.css. This is the direction the check does cover — it simply was not running.Both are corrected in #3033 (322a9ce) by running
scripts/generate-astryx-surface-inventory.mjsrather than editing either half by hand. That fixes the current state, not the gap.Proposed change
check-astryx-surface-inventory.mjsfail on inventory rows with no file on disk, in both.pathsand the Markdown table, so the check is symmetric.npmscript and wire it into thechanges-gated CI path so it runs when surface files move.The hand-editing is the root cause: a generated file maintained in halves drifts in whichever half the author forgets. A check that only runs one direction and only when someone remembers to run it cannot catch that.
Generated-by: Claude Code