refactor(contracts): derive snapshot producer facts from one registry

Merged
TH
16h ago
+872-343

Summary

Step 4 of #4205. @agent-device/contracts/snapshot-producers holds the one producer registry (SNAPSHOT_PRODUCERS), its row lookup, and stampSnapshotIdentity. The 11 old producer tables now derive from it, with no producer value changed. Every one-source owner stamps identity through that function. The snapshot facade does not re-export the registry, so R74 is a plain import ban for the assembly files. 31 files.

  • Revyl Android now reports revyl-android-tree instead of appium-source. It shows only in snapshotDiagnostics.stats.backends.
  • thymikee approved the new module in APPROVED_CLOSURE_ADDITIONS: +1 module, +5 to +9 statements per closure.
  • ADR 0038 names the new home.

Validation

Tested SHA: 4015fc5703.

  • pnpm check:affected --run --head 4015fc5703: 42 passed, exactCommit=true, all runnable checks passed.
  • node --test scripts/layering/*.test.ts: 483/483. pnpm typecheck and pnpm check:layering: OK.
  • Vitest for contracts, capture-kit, command-runtime and the emitter guard: 2435/2435. Eager-closure budget: 903/903.
  • Live parity: the coordinator reruns it.
Guards and deleted controls
  • R74 controls: aliased, namespace, type-only, re-export and dynamic imports, plus a missing registry. R18 is unchanged.
  • Deleted R74 controls: member, computed-key and destructured namespace reads, a namespace passed on whole, four re-export-chain forms, and the non-registry namespace test.
  • Given up: a read through another local module that re-exports the registry.
  • The emitter guard counts the two stamp calls and the bridge-source.ts capture object. Its controls: an unemitted row, an unlisted producer, and a cut bridge emission. Deleted: imported-constant aliases and kind-tagged objects.

Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.