ci: enforce unused runtime exports in the web app#10228

merged1
cleanup-web/app-internals
cleanup-web/knip-gate
openedSep 5, 2026byJJulius Marminge
View on GitHubTwo-way sync enabledPR last imported 3d ago

Web runtime exports are not covered by the existing Knip CI gate. Add apps/web alongside the seven internal packages after the preceding cleanup layers.

Keep exported types and Effect schemas under the existing preprocessor policy. Web UI component modules are copied and adapted as complete component sets, so Knip ignores named exports and duplicate aliases in apps/web/src/components/ui/*.tsx. The exception does not include file findings: an unimported UI component module still fails the file audit.

No dependency or plugin changes. Before this cleanup, the ordinary scan reported 205 web runtime exports and three duplicate-export groups. The integrated stack now passes under the revised policy. Production-only findings remain a separate audit because tests can legitimately consume meaningful logic.

Layer 4 of 4 in the web runtime-export cleanup stack. Based on #10227.

Verification at the integrated stack tip: vp run --filter @t3tools/web test passes all 4,052 tests across 333 files. Web typecheck and changed-file lint/format pass. vp run knip:check passes. A negative probe confirmed that a wholly unused components/ui/*.tsx file still fails the file audit.

Model: gpt-6 astra. Harness: Codex in T3 Code.

Note

Add apps/web to knip:check and ignore export findings for UI components

  • Extends knip:check in package.json to audit files, dependencies, and exports in apps/web.
  • Adds an ignoreIssues rule in knip.jsonc for src/components/ui/*.tsx to suppress export-level findings, treating these files as cohesive sets while still reporting fully unused files.
  • Updates docs/operations/development.md to document the expanded audit scope and component rules.
  • Behavioral Change: Running knip:check now audits apps/web, which may fail CI if unused files or dependencies exist outside the ignored UI components.

Macroscope summarized 78ed671.

Synced from GitHub

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

ℹ️ No successful main baseline artifact is available yet. This run establishes the initial measurement.

ProviderMetricMain baselineThis PRImpactPR ceiling
CodexTotal thread wire—13.5 KiB—15.1 KiB✅
CodexThread snapshot wire—7.0 KiB—7.3 KiB✅
CodexLive turn WebSocket wire—6.5 KiB—7.8 KiB✅
CodexLive turn WebSocket decoded—57.0 KiB—66.4 KiB✅
CodexLive turn messages—8—21✅
ClaudeTotal thread wire—13.5 KiB—15.1 KiB✅
ClaudeThread snapshot wire—7.0 KiB—7.3 KiB✅
ClaudeLive turn WebSocket wire—6.5 KiB—7.8 KiB✅
ClaudeLive turn WebSocket decoded—57.8 KiB—66.4 KiB✅
ClaudeLive turn messages—9—21✅

Baseline: unavailable · PR result: 78ed671 · Source CI: success

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 113.8 KiB
  • Claude decoded thread snapshot: 114.5 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

Synced from GitHub

Approvability

Verdict: Not approved

Macroscope's review found this PR not approvable — The PR is limited to CI coverage, Knip configuration, and documentation, with no product runtime or default changes. Human review is still required because the new Knip configuration suppresses export-related diagnostics for a class of web UI modules.

You can add or adjust custom eligibility rules. Learn more.

Added 1 commit

  • ci: enforce unused runtime exports in the web app78ed671
Synced from GitHub

Bugbot is paused — on-demand spend limit reached

Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.