Skip to content

tooling(objectui-readiness 4): objectui scripts address git paths relative to the repo root — git show ref:packages/…, diff --name-only, ls-files, ls-tree break one level down in ui/; prefix via nestedPrefix() (parent #25677, 2d/6) #25728

Closed

Description

@objectstack-fleet

Filing gate ④: sub-issue 2d/6 of the epic #25677 (pm:epic; epic PM session_01RSDL3SFtJaKzcymvCD8RsU). Part of #25677. ⛔ Not a claim. Follow-up of #25723 (objectui#13484), measured on the DO NOT MERGE verification PR #25718, run 4 (40149547507, head d17ed5e).

Why. #25723 made objectui's scripts find the workspace root (pnpm-workspace.yaml, pnpm-lock.yaml, turbo.json) when the tree is ui/ of the objectstack monorepo. Run 4 shows the second half of the same class: scripts that hand paths to git. A path in git show <ref>:packages/i18n/src/locales/en.ts, in git ls-tree <ref> packages/…, or matched against git diff --name-only / git ls-files output is relative to the git repository root, not to the script's working directory — so in the merged tree every such path is missing its ui/ prefix, whatever cwd the script runs git with. First casualty: Type Check UI red at check:i18n-drift, cannot read b77bb37eb2…:packages/i18n/src/locales/en.ts — is b77bb37eb2 in this clone? — the ref is objectstack's merge-base and is in the clone; the path is wrong. Everything downstream of that step (check:i18n-designer-parity, type-check:scripts / vitest-config / e2e, the tsc run over the ui packages) has not run in CI yet. The cutover PR cannot be green until this class is fixed, and like #25723 it is fixed in objectui main first so the import carries it.

Who does it, where it lands: the epic PM dispatches it (os-dev, objectui checkout). One PR to objectstack-ai/objectui main; the epic PM re-measures on the verification branch and records the remaining reds on #25697.

维护者速读

#25723 让 objectui 的脚本在 ui/ 子目录里能找到工作区根文件。第四轮验证暴露了同一类问题的另一半:给 git 传路径的脚本。git show ref:packages/…、git ls-tree、以及对 git diff --name-only / git ls-files 输出做匹配的脚本,路径都是相对 git 仓库根 而不是脚本所在目录,所以在合并后的树里全部少了 ui/ 前缀。第一个倒下的是 check:i18n-drift(Type Check UI 在这一步红),后面的 tsc 还没跑到。本卡让这些脚本用 #25723 已经提供的 nestedPrefix()(或 git 自身的 ref:./path、--relative)补前缀,先落 objectui main。不改受管面。

Measured

Evidence Reading
#25718 run 4 Type Check UI lucide check:icon-record-names and check:i18n-keys green after the verify commit; red at check:i18n-drift: cannot read b77bb37eb2c738c40093acb04f19fa8fc2dd605a:packages/i18n/src/locales/en.ts (scripts/check-i18n-en-drift.mjs:340). git cat-file -t b77bb37eb2 in the same clone = commit (objectstack's merge-base with origin/main), so the ref resolves and the path does not
Local, merged tree at d17ed5e check:i18n-drift reproduces exactly; check:i18n-designer-parity, type-check:scripts, type-check:vitest-config, type-check:e2e green when run after it
Census (ui/scripts/*.mjs) 31 scripts spawn git show / diff / ls-files / ls-tree / log / cat-file; not all of them hand git a path or match root-relative output — the dev triages. Heaviest: check-changeset-claims.mjs (11 calls), check-changeset-presence.mjs (7), check-readme-exports.mjs (6), check-new-cross-file-line-citations.mjs (6), check-vi-mock-inherit.mjs (5), check-vi-mock-specifiers.mjs (5), markdown-test-inputs.mjs (4), select-affected-tests.mjs (3), check-test-path-roots.mjs (3), check-i18n-en-drift.mjs (3), check-lockfile-integrity.mjs (3), check-comment-mask-corpus.mjs (3)

Scope

  1. Triage the 31 scripts: for each git call, classify (a) path into git (show ref:path, ls-tree ref path, diff -- path, log -- path), (b) root-relative path out of git (diff --name-only, ls-files, ls-tree output) matched against packages/…-shaped literals or globs, (c) no path involved (rev-parse, merge-base, cat-file -t) — (c) needs nothing.
  2. Fix (a) and (b) with one idiom, chosen by the dev and written down in scripts/workspace-root.mjs's header: either prefix with nestedPrefix(root) ('' standalone, 'ui/' merged), or use git's own cwd-relative forms (ref:./path, --relative, ls-files run from the tree) — not a mix per script.
  3. Extend check-ui-root-lookups (or the gate tooling(objectui-readiness 2): scripts, tests and e2e specs that read pnpm-workspace.yaml, turbo.json, pnpm-lock.yaml or root overrides at the objectui root resolve the workspace root upward (parent #25677, 2b/6) #25723 taught the walk shape) so a new git show …:packages/ / ls-tree … packages/ literal without the prefix helper is refused — the class must not regrow before cutover.
  4. Tests: the merged-layout verification tooling(objectui-readiness 2): scripts, tests and e2e specs that read pnpm-workspace.yaml, turbo.json, pnpm-lock.yaml or root overrides at the objectui root resolve the workspace root upward (parent #25677, 2b/6) #25723 established (scratch copy of the verification worktree) run for every fixed script; scripts/__tests__ for the touched scripts, the whole suite once (objectui gate chains).

Out of scope: the lucide record-icon list (regenerated, separate class), the dependency-resolution class (#25726), the spec drift (#25727), anything under .github/**.

Verification (the dev's)

  • objectui standalone: pnpm check:i18n-drift, pnpm check:changeset-presence, the other touched gates, pnpm exec vitest run scripts/__tests__ — green, no gate skipped; CI green.
  • Merged layout (scratch copy of /home/claude/objectstack-issue-25697 with the patch applied under ui/): pnpm --dir ui run check:i18n-drift finds the merge-base pack; every triaged (a)/(b) script runs to its real verdict instead of a path error.
  • The epic PM: the same patch as a verify commit on DO NOT MERGE — verification run for #25697: PR A + the ui/ subtree import of objectui main cd70b7818d #25718 → run 5; Type Check UI reaches the tsc step.

Done when

Size: M (31 scripts to triage, ~10–15 to touch, one gate extension). Clause-②: no. Metadata-protocol: none. Blocked-by: objectui#13484 (#25723) must land first — same files (scripts/workspace-root.mjs, check-ui-root-lookups) and the same objectui branch.

风险

  • Shallow CI clones: a few gates fall back to "cannot find merge-base" paths; the fix must keep that fallback and only change the path part (the run-4 clone had the ref).
  • Mixed idioms (some scripts ./path, some nestedPrefix) make the regrowth gate hard to write; one idiom.

Dedupe

Open issues 2026-10-25 01:35Z filtered on nestedPrefix / ls-tree / git show / check-i18n-en-drift: #25723 (objectui#13484 in the merge queue) covers file readers only, its body names git paths as a follow-up; nothing else. New.

Activity

  1. added
    toolingFix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface
    priority:p1High: required for production / M2
    domain:devxDomain lane — seat card indexed by label:pm:seat
    pm:epicReserved by a dedicated epic PM, parent or sub-issue; other PMs never take it; never with pm:queue
    area:devpathThe road — create, dev, verify, publish/install, connect an agent, iterate
    pm:dispatchedDispatched to a dev agent by /pm-dispatch
    on Oct 25, 2026
  2. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    Claim: epic #25677 round 5 (card threads; Tesla 2026-10-25 「你应该使用 pm-dispatch 技能派发」「并发可以到6」)
    Session: session_01RSDL3SFtJaKzcymvCD8RsU
    Account: os-tesla
    Branch: claude/project-thread-ulxm6b (the card thread's designated branch in objectstack-ai/objectui — the thread can push only this branch, a measured platform exception to claude/issue-<n>-<slug>)
    Worktree: objectui-issue-25728
    Domain: domain:devx
    Seat: epic:#25677
    File surface: scripts/*.mjs that hand git a path or match root-relative git output (≈31 to triage), scripts/workspace-root.mjs header, the check-ui-root-lookups gate + its tests under scripts/__tests__/; no package code, no .github/**
    Container & model: M, mode:thread (thread session session_011zu1DRQQFNb42ves1suAuk; order: /mnt/project-files/d1-merge/dispatch/ in the project, FRAME.md + the card's file), model: opus, effort: high (coordinator default)
    Clause-②: no
    Metadata-protocol: none
    Responsibility: n/a — not a defect card
    Thread-read: none
    Serial constraints cleared: objectui#13484 (#25723) MERGED as c85408f — this card branches from main past it (same files, now settled); #25727 (2c) edits .objectstack-sha + packages/**, no overlap


    Generated by Claude Code

  3. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    ACCEPT — dispatch seat. objectui#13491 (head f8fa141862, branch claude/project-thread-ulxm6b, +463/−30, 11 files) is accepted as the fix for this card.

    Checked against the order (/mnt/project-files/d1-merge/dispatch/2d-25728-objectui-git-paths.md):

    • Idiom is git's cwd-relative forms (ref:./p via revPath, --relative on listings; no --full-tree / --full-name), written down in the scripts/workspace-root.mjs header. 15 sites fixed across check-i18n-en-drift, check-changeset-presence, check-changeset-claims, check-changeset-overwrite, check-lockfile-integrity, select-affected-tests, bump-objectstack.test.ts.
    • Regrowth gate: check:ui-root-lookups learns two more shapes (git-rev-path, git-root-listing), 20 new self-test cases; on the pre-fix tree it fires at exactly the 15 sites. check-governed-queue-guard is allowlisted on purpose (it judges the repository root; see objectstack#25712).
    • Merged-layout verification on a scratch copy of the verify head: control reproduces the run-4 check:i18n-drift red; with the patch the whole Type Check UI script chain (21 steps, type-check:coverage → type-check:e2e) exits 0. The turbo tsc step is objectstack#25727's class and was not run.
    • Deviation accepted: the run-4 merge base b77bb37eb2 has no ui/ tree, so check:i18n-drift treats "tree absent at the base" as an empty before side and says so; a pack missing from a present tree still throws, with a test. The order's "must find the merge-base pack" cannot hold on the verify branch or on the cutover PR itself, so this reading is the right one.
    • CI on the PR head: 36/36 checks green (incl. Type Check, Build & E2E, 16 test shards, Repo Gates, Lint). check-governed-merges --pr objectstack-ai/objectui#13491: NOT governed (0 of 11 paths hit the register), 493 changed lines ≤ 3000 — ordinary queue landing.
    • Writes: 1 relay write (pr_create), 0 MCP writes, no review requested.

    Landing: the seat flips the PR ready and arms auto-merge via the relay now. The PR body says Part of objectstack#25728 (cross-repo, no auto-close), so the seat closes this card with a landing note once the merge lands; the parent #25677 ticks item 2d then. Follow-on: the verify branch objectstack#25718 picks the merged objectui main up at the next subtree refresh (cutover prep, child 5).


    Generated by Claude Code

  4. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    Landed — dispatch seat. objectui#13491 merged to objectui main via the merge queue at 03:43Z (queued 02:42Z; the queue was held for an hour by its head entry, Dependabot objectui#13438, whose queue checks did not report until then). The 15 git root-relative sites now use cwd-relative forms, and check:ui-root-lookups guards the two new shapes against regrowth.

    Closing this card. Parent #25677 ticks item 2d. Follow-on: child 2e (#25733) was gated on this merge and may branch now; the verification branch #25718 picks the merged objectui main up at its next subtree refresh (run 6), where the Type Check UI check:i18n-drift red is expected to clear.


    Generated by Claude Code

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

Metadata

Metadata

Assignees

Labels

area:devpathThe road — create, dev, verify, publish/install, connect an agent, iteratedomain:devxDomain lane — seat card indexed by label:pm:seatpm:dispatchedDispatched to a dev agent by /pm-dispatchpm:epicReserved by a dedicated epic PM, parent or sub-issue; other PMs never take it; never with pm:queuepriority:p1High: required for production / M2toolingFix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions