Skip to content

finding(ci): check:unused-deps has no ci.yml step — it is enforced only through its pin test, unlike its sibling check:phantom-deps #8301

Description

@claude

Split out of objectui#8198. The gate landed; its CI wiring did not, because .github/workflows/** was outside that session's declared file surface.

Where it stands

pnpm check:unused-deps (scripts/check-unused-dependencies.mjs) is green on main and IS enforced today — but only through its pin test, scripts/__tests__/check-unused-dependencies.test.ts, whose this repository is green case runs inside pnpm test. Its sibling check:phantom-deps has a dedicated step in ci.yml (around line 251) alongside check:self-import, check:unreferenced-sources and the rest of that block.

Why the pin test is not the same thing

Two differences, both real:

  • Attribution. A failure surfaces as one assertion inside a 117-file scripts suite rather than as a named CI step. The failing output — which names the package, the field, the key and the scan that found no consumer — is what a contributor needs, and it is easier to find when the step is named after the gate.
  • Cost placement. The scripts suite is in the heavy half. A node scripts/check-unused-dependencies.mjs step is install-only and takes about a second, so it belongs in the cheap half beside its sibling, where it fails fast.

What to do

Add one step to .github/workflows/ci.yml beside the pnpm check:phantom-deps step, matching that block's spelling:

      - name: Verify no released package declares a dependency nothing consumes
        run: pnpm check:unused-deps

Whether the pin test's repository-green case should then be trimmed is a separate judgement — objectui#8198's view was that both are worth keeping (the pin test is the build-free half and catches a regression in the same PR that causes it), but a maintainer may prefer one.

Filed unassigned by the objectui#8198 implementation session.


Generated by Claude Code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions