Skip to content

Ownership guard summary: a collect failure in error mode shows its cause's route, not the file's #880

Open

Description

@danfry1

Under ownership: 'error' with diagnostics: true, a test file whose collection fails on a conflict is listed in the guard's summary with its cause's route, and with no loader. The file's own route is not used.

plugin.ts calls this.add(route, origin?.[1] ?? match[1], match[1], test) on that path without the reached argument, so reached defaults to { route }, which is the origin's route. The thrown error already carries the file's own route -> … line, so the right label is available there.

Only one file per test file takes this path, because error mode throws at the first conflict.

Acceptance criteria

  • On the collect-failure path, the summary names the file's own route and loader, as the warn path does.
  • A test covers that path, and another covers one file reached through several causes.

Found while reviewing #809.

Activity

  1. added this to the 0.16.0 milestone on Nov 15, 2026
  2. added
    bug
    area:ownership
    priority:low
    on Nov 15, 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

    area:ownershipbugpriority:low

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions