chore: drop unused production exports and suppress dynamic consumers

Merged
TH
2mo ago
+41-11

Summary

Drops production exports that nothing consumes, and suppresses the ones fallow cannot see. Unused production exports go from 70 to 50, with 0 stale suppressions. The 50 left are test-only exports, left on purpose, so pnpm check:production-exports still exits 1.

  • Barrel re-exports deleted: freezeJsonObject, isBoundedJsonObject (packages/capture-kit/src/index.ts), PERF_MEMORY_KIND_ERROR_MESSAGE (packages/contracts/src/facades/observability.ts), isCloudWebDriverProviderName (packages/provider-webdriver/src/index.ts).
  • Dead declarations deleted: isAudioProbeSupportedDevice (packages/contracts/src/audio-probe-support.ts), PERF_MEMORY_KIND_ERROR_MESSAGE (packages/contracts/src/perf.ts). Neither had a consumer or a test. perf-runtime-plan.ts:146 already spells the message inline.
  • .fallowrc.json ignoreExports: 14 exports that production code reads through dynamic import() member access, which fallow cannot follow. Same shape as the existing runner-operations-facade entry.
  • findSnapshotScopeRange facade re-export restored and suppressed. Deleting it failed the "façade re-exports its sources exhaustively" check in scripts/layering/package-boundaries.test.ts.
  • No public API of the root package is touched: src/runtime.ts is not in the package exports map.

Mutation table: not applicable. No behavior changed, and no tests were added or removed. The facade-exhaustiveness test is red when the findSnapshotScopeRange line is removed and green when it is restored.

Live evidence for #3096: none beyond the gates below. These are export-surface changes only, and none of the removed symbols had a consumer. The dynamic consumers were verified by reading the call sites, not by a runtime trace.

Validation

  • pnpm typecheck: pass
  • pnpm lint: pass
  • pnpm check:layering: pass (255 tests)
  • pnpm check:fallow --base c973d3867d: no issues
  • pnpm check:production-exports: 70 to 50, 0 stale suppressions
  • pnpm check:affected --run (under the host mutex): exit 0, "all runnable checks passed"

Part of #3069.