Skip to content

Report Downstream Copies When a Whole Tree Declaration Is Dropped #4272

Closed

Description

@ptr727

Problem

Dropping a whole trees declaration from spec/files.json leaves every downstream copy under its target unreported.

  • The verbatim-tree check stops running for a tree the manifest no longer declares, so its prune never fires again.
  • The hub-only check matches hub paths only. For a tree whose target differs from its source, such as lib/sh carried to lib/fleet/sh, no downstream path under the target is ever a hub path.
  • spec/validate.py CARRIED_PATH_PINS pins baseline paths only, so the drop check added for dropped baseline files does not see a dropped tree.

dropped_carry_errors' docstring states this limit. A local strict review on the retired-path lane raised it, and the maintainer chose to file it rather than extend that pull request.

Done when

Removing a trees declaration fails a check until a decision about its target's downstream copies is recorded. One shape is a pinned set of declared tree targets with a fleet-wide gaps row owed when one disappears, mirroring the baseline pins. Another is the audit itself reporting copies under a retired tree target.

🤖 Generated with Claude Code

Activity

  1. ptr727 commented on Nov 19, 2026

    @ptr727
    OwnerAuthor

    Scope chosen by the maintainer, 2026-11-19: accept-only pins.

    • spec/validate.py pins the declared tree targets, mirroring CARRIED_PATH_PINS. A pinned target the manifest no longer declares fails validation until a fleet-wide gaps row records the decision.
    • That row's disposition is accepted. retire is refused for a tree target, with a message saying why: the audit compares retired rows to downstream file paths only, so a directory row would delete nothing.
    • The audit is not changed, since spec/audit.py is at 2983 of its 3000-line ceiling. Mechanical deletion advice for a retired tree's copies is a separate follow-up, filed when this lands.
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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions