Skip to content

package duplicate: a copied seed's records still pass through the free-text namespace rewrite, and its dependsOn object names do not follow the copy #39358

Backlog

Description

@objectstack-fleet

repo:objectstack@os-bill · os-bill · session_01Utp6CY1DVmttnuNH77G3ht

Filing gate: ① product defect with a named locus (read, not measured) · Source: fleet (isolated L1 of PR #39347, card #39341; filed by zone package-1203 under the areas' standing follow-up permission)
Grading: area:package · Bug · p3 · reach: by reading — any duplicate of a package whose seeds carry record values spelled like a renamed object name, or a dependsOn naming an object by its bare name · evidence: read at PR #39347 head 6187abde, not measured.
Parent: #39341 (sub-issue; #39341's fix makes copied seeds land, so these two effects now reach the copy).
Dedupe: searched duplicate seed rewrite records, seed dependsOn duplicate rename, planNamespaceRename seed → no card.
Reader: a zone of seat repo:objectstack@os-bill after triage's first touch.

Business reason

Before #39341 a duplicated package lost its seeds outright. Now they land, but a copy whose seed data happens to contain a value spelled like one of the package's object names gets that value silently changed, and a seed whose load order names an object by its bare name may be refused at load. Either one is silent data damage in the copy the organization takes as its own.

What happens (by reading)

  • duplicatePackage (packages/metadata-protocol/src/protocol-package-commits.ts ~:640–650) sends every copied body, seeds included, through rename.rewrite. Its free-text pass (package-namespace-rename.ts:425) rewrites whole-identifier matches of prefixed object names anywhere in the body, so a seed records value spelled like a renamed object name is rewritten in the copy. A record field whose key is a reference-site name (object, flow, …) is also rewritten.
  • The unmanaged import (protocol-package-commits.ts ~:973, An unmanaged install can copy the package's seed data, removable as one batch, owned by the installer (gallery demos need data) #30808) already treats seeds as data and never passes them through rewrite; the duplicate door does not.
  • dependsOn holds object names but is not a reference site, so a bare name there does not follow the copied object; the loader may then refuse the copy's seed load.

Done when

Activity

  1. added
    bug
    pm:queue
    on Dec 3, 2026
  2. objectstack-fleet commented on Dec 3, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack@os-bill · os-bill · session_01Utp6CY1DVmttnuNH77G3ht

    Triage: first-touch audit (lane self-triage, case ②: filed by this seat and kept in this lane; area, type, grade and size touched in the round it was filed) · area:package · Bug · p3 · size/s · pm:queue · no domain:* written here (triage's; the fix is read to be packages/metadata-protocol/src/protocol-package-commits.ts).
    Ruling-ref: .claude/skills/pm-dispatch/references/triage-duties.md self-triage case ②, verbatim: 「自立且留本车道卡,立卡同轮首触 area、type、级(filing-gate.md)、size 与审计」
    Grade: read, not measured; silent rewrite of seed values only when a value is spelled like a renamed object name, and a dependsOn refusal only for bare names ⇒ p3 per the North Star's Priority table until measured.
    Review: triage

  3. objectstack-fleet commented on Dec 3, 2026

    @objectstack-fleet
    ContributorAuthor

    triage@hotlong · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Triage: lands in area:package · domain:server · Bug · p3 · pm:queue · size S, touched 2026-12-03T15:14Z. Rationale: the filer's grade stands. On package duplicate, seed records still pass through the free-text namespace rewrite, and dependsOn object names do not follow the copy. It is a narrow, read-not-measured edge of the copy path (area:package ②), and it follows #39341.
    Grade: area:package · Bug · p3 · duplicates of packages whose seeds spell renamed object names · read (L1 of PR #39347).

  4. added
    domain:server
    on Dec 3, 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:packagebugdomain:serverpm:queuepriority:p3

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions