Skip to content

[Task]: scan .tsx in the duplicates gate #199

Open

Description

@PerfectPan

Problem

pnpm duplicates runs jscpd with --format 'typescript,javascript'. jscpd treats tsx as its own format, so the 75 non-test .tsx files under the scan roots are not checked, although the ignore list already names **/*.test.tsx. CI runs the gate since #198, so a new .tsx clone still passes.

With tsx added to --format, main reports 8 clones (74 lines):

Clone Files
1 apps/room-web/app/routes/room.$roomId.tsx [47-54] / room.agents.tsx [33-40]
2 apps/room-web/app/routes/room._index.tsx [33-39] / room.agents.tsx [31-37]
3 apps/room-web/app/routes/task.$taskId.tsx [50-58] / same file [58-66]
4 packages/agent-finder-cli/src/commands/sessions-browse-command.tsx [30-38] / packages/agent-task-loop/src/commands/tui.tsx [53-62]
5 packages/agent-task-loop/src/tui/components/session-preview.tsx [40-52] / task-detail.tsx [17-29]
6 session-preview.tsx [41-52] / task-list.tsx [39-50]
7 source-filter.tsx [54-60] / task-form.tsx [164-170]
8 task-detail.tsx [21-29] / task-list.tsx [42-50]

Clone 4 crosses two published packages, so sharing it needs a dependency between them or an ignore with a reason.

Proposed Solution

Resolve the 8 clones (share the code, or add an ignore to the script with the reason in the PR), then add tsx to the script's --format in the same PR.

Acceptance Criteria

  • --format includes tsx, and pnpm duplicates reports 0 clones on the PR and in CI.
  • Every ignore added for these clones names its reason in the PR.

Activity

  1. added
    taskMaintenance, refactoring, dependency, or tooling work
    on Nov 18, 2026
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

    taskMaintenance, refactoring, dependency, or tooling work

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions