Skip to content

test(ui/scripts): the inputs guards and the lychee pins read the configs that run; ui/lychee.toml is deleted, ui/turbo.objectui.json stays - #27281

Merged
objectstack-fleet[bot] merged 5 commits into
mainfrom
claude/issue-26080-parked-configs
Oct 28, 2026
Merged

objectstack-fleet[bot] merged 5 commits into
mainfrom
claude/issue-26080-parked-configs

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Part of #26080
Clause-②: no
Metadata-protocol: none

维护者速读

  • 改了什么:实测确认 ui/turbo.objectui.json 和 ui/lychee.toml 没有任何真实运行会读(turbo 只解析根 turbo.json,check-links.yml 只读根 lychee.toml)。三组守卫原本对着这两份死配置断言,现在改读真正生效的根配置:type-check 输入守卫、包级 lint 输入守卫、lychee「不许有 remap」守卫。断言一条没删,也没放宽。另把 lychee 的站内路由守卫改为读 check-links.yml 的 lychee 参数(只读不改 workflow),ui/lychee.toml 已无读者,删除。
  • 为什么改:守卫对着死文件断言,根配置漂了也照样是绿的。改完之后,从根 turbo.json 删掉一条 ui 输入,立刻红 38 条。
  • 风险与回滚:只改 ui/scripts/__tests__ 下的 4 个测试文件与 1 份死配置,不动运行时、构建配置、workflow,也不动任何发布包;回滚 = revert。ui/lychee.toml 已删;ui/turbo.objectui.json 这次不删:用根配置去跑旧断言会红 147 条,其中不少属性在根配置里根本没有对应项。按裁决不许放宽,这些守卫只能继续读旧文件,具体列在 Acceptance notes,要你来定。
  • 先看:1) ui/scripts/__tests__/helpers/turbo-inputs.ts(新增 liveTurboConfig / parkedTurboConfig,默认值仍是旧文件);2) ui/scripts/__tests__/check-links-workflow.test.ts 的 liveLycheeConfigPath;3) Acceptance notes 第一条:根 build 任务没有哈希 ui 的根脚本。
  • 两分钟验证:pnpm --dir ui exec vitest run scripts/__tests__/turbo-type-check-inputs.test.ts scripts/__tests__/turbo-lint-inputs.test.ts scripts/__tests__/check-links-workflow.test.ts,预期 3 个文件全绿;在根 turbo.json 的 type-check.inputs 里删掉 "$TURBO_ROOT$/ui/tsconfig.json", 再跑,预期 type-check 守卫红。
  • 需要你做的:无,席位落地(根 turbo.json 的 ui 输入缺口由席位另立卡 [devx] root turbo.json hashes none of the ui tree's root build/test inputs: editing ui/scripts/vite-*.ts or ui/tsconfig.json can replay a stale @object-ui/* build from cache #27283)。

What changes

Slice 2 of ruling A, item (3): ui/turbo.objectui.json and ui/lychee.toml.

Measured: no real run on main reads either file (readings below). Every turbo invocation, whether in workflows, the root package.json scripts, or turbo's own config resolution, resolves the root turbo.json plus the package-level ui/apps/console/turbo.json. Turbo has no flag here that names another root config, and none is passed. check-links.yml passes --config lychee.toml from the repository root, and no workflow reads ui/lychee.toml. So both files are dead config, read only by tests.

The retarget. The live counterpart of the parked turbo config is uiScopedTurboConfig() (ui/scripts/workspace-root.mjs): the root turbo.json, narrowed to the ui/ subset. It is the same reader the production select-type-check-scope.mjs already uses. Swapping the parked file's content for that live config (probe below) sorts each guard into one of two groups.

Reader Live counterpart holds? This PR
turbo-type-check-inputs.test.ts (via helpers/turbo-inputs.ts) yes, all cases reads liveTurboConfig()
turbo-lint-inputs.test.ts, the package lint describe yes reads liveTurboConfig()
turbo-lint-inputs.test.ts, the //#lint:root describe no (5 red) unchanged, parked
turbo-build-inputs.test.ts no (38 red) unchanged, parked
turbo-test-inputs.test.ts no (41 red) unchanged, parked
turbo-task-guard-coverage.test.ts no (55 red) unchanged, parked
check-dist-completeness.test.ts (build-input case) no (1 red) unchanged, parked
e2e-type-check.test.ts (wiring cases) no (4 red) unchanged, parked
select-type-check-scope.test.ts no (2 red) unchanged, parked
turbo-build-outputs-cover-published-entries.test.ts no (1 red) unchanged, parked
workspace-root.test.ts (uiTurboConfigPath itself) n/a, pins the resolver unchanged
check-links-workflow.test.ts, "carries no remap" yes (root file has no remap) reads the root lychee.toml
check-links-workflow.test.ts, site-route pin yes: restated against check-links.yml LYCHEE_ARGS (--config lychee.toml, absolute --root-dir over the docs tree, --fallback-extensions mdx,md) reads the workflow argv

ui/lychee.toml has no reader left and is deleted.

helpers/turbo-inputs.ts now exports liveTurboConfig() and parkedTurboConfig(). taskInputs / rootAnchoredInputs take the config as an optional second argument, defaulting to the parked copy, so every guard not listed as retargeted reads exactly what it read before. ui/turbo.objectui.json is not deleted. Readers whose property has no live counterpart still need them, and the ruling forbids loosening those guards. See Acceptance notes.

Item (2), checked: ui/docs/adr's index prefix is settled on main. PR #26503 merged as 79cd9ef8 (git merge-base --is-ancestor 79cd9ef8 HEAD → exit 0, a self-proving leg). docs/adr/README.md:11 and :215 list the ObjectUI registry under the ui- prefix, with files untouched, and scripts/adr-index.mjs generates it. No edit is needed, and none is made. A pointer would land in ui/docs/adr/** (governed) and buys nothing.

Tests

  • pnpm --dir ui exec vitest run --maxWorkers=2 scripts/ on head 88bd2bb7 (lock VERDICT command-exit 0): Test Files 174 passed | 2 skipped (176), Tests 5003 passed | 2 skipped (5005).
  • The 11 reader files, before and after the change: 11 passed, 338 tests, both times. That is the same count, so no case was dropped.
  • pnpm --dir ui run type-check:scripts: exit 0.
  • Teeth. Each mutation was made on disk and verified, then restored. The restore was proven by git hash-object = the HEAD blob, plus an empty git status --porcelain.
    • node scripts/ablation-replace.mjs --file turbo.json --anchor '"$TURBO_ROOT$/ui/tsconfig.json",' --delete (anchor 1 → 0, blob 6d3dece1ae49 → 5b5820c9f5f8). Result: turbo-type-check-inputs.test.ts 38 failed (one per @object-ui/* package). Before this PR, the same root edit could not reach that guard: it read only the parked copy.
    • Appending remap = [...] to the root lychee.toml (grep -c '^remap' 0 → 1). Result: "carries no remap pretending to resolve fumadocs routes" failed.
    • Deleting --root-dir, then --fallback-extensions, from the on-disk check-links.yml (ablation-replace, blob fd75bd9ccaee restored by hash, never committed) turns the site-route pin red with its own message each time.

Acceptance notes

  1. Open question: the live root build and test tasks do not hash the ui tree's root files.
    • The parked copy declares $TURBO_ROOT$/tsconfig.json, scripts/vite-*.ts, scripts/build-plugin-stylesheet.mjs, scripts/check-dist-completeness.mjs, scripts/invoked-as.mjs and scripts/vitest-invocation-guard.mjs for build, plus the vitest config and setup set for test.
    • The root turbo.json carries none of them under ui/. Measured: pnpm exec turbo run build --filter=@object-ui/components --dry=json → the task's root-anchored inputs are exactly scripts/check-dts-emitted.mjs, scripts/invoked-as.mjs and scripts/tsup-drop-sources-content.mjs. Meanwhile ui/packages/components/vite.config.ts:14-15 imports ui/scripts/vite-dts-*.ts, and its tsconfig.json extends ui/tsconfig.json.
    • So an edit to either file replays a cached @object-ui/* build in any turbo run build that includes ui packages (root pnpm build).
    • The guards that would catch this (turbo-build-inputs, turbo-test-inputs, check-dist-completeness's build-input case) stay green because they read the dead copy.
    • Options:
      • A: port the ui entries into the root build / test inputs. Every @objectstack/* package then also hashes them, so this edits the real cache keys. Then retarget those guards and delete the parked file.
      • B: give the ui packages package-level turbo.json files that extend the root.
      • C: keep the status quo.
    • Recommendation: A, because it closes the stale-replay path and makes the parked file deletable. It is a root turbo.json behaviour change, so it is its own card, not this slice. Seat: [devx] root turbo.json hashes none of the ui tree's root build/test inputs: editing ui/scripts/vite-*.ts or ui/tsconfig.json can replay a stale @object-ui/* build from cache #27283 carries the root turbo.json ui-input gap, with these guards riding it.
  2. Open question: the properties that have no live counterpart by construction.
  3. Resolved in this PR (seat answer A): the site-route pin is restated against the live argv, and ui/lychee.toml is deleted.
  4. select-type-check-scope.test.ts drives the selector with the parked config, while the selector in production (select-type-check-scope.mjs:324) reads uiScopedTurboConfig. Against the live config, two cases go red: e2e files no longer widen, because //#type-check:e2e does not exist there. The test stays as is (point 2).
  5. turbo-build-outputs-cover-published-entries: ui/apps/console/turbo.json restates the parked build.outputs, not the root's (it lacks json-schema/** and !.next/cache/**). The "no package configuration narrows the root outputs" case is the one red against live. It is noted only: console emits neither path.

Verification

Reading 1: no turbo invocation names the parked file
$ git grep -n -i 'root-turbo-json\|ROOT_TURBO_JSON\|turbo.objectui' -- . ':!ui/CHANGELOG.md' | grep -v '^ui/scripts/__tests__\|^ui/scripts/workspace-root'
(no hits; the only hits outside those two paths are vscode-extension `*.objectui.json` schema-file globs, a different thing)
$ find . -name turbo.json -not -path '*/node_modules/*'
./turbo.json
./ui/apps/console/turbo.json          # "extends": ["//"]
$ grep -n 'turbo' package.json         # root scripts: build, spec:rebuild, test, test:smoke, typecheck, clean, console:build -- all plain `turbo run`
$ grep -n '"turbo \|turbo run' ui/package.json
(no hits)
$ grep -n 'turbo run' .github/workflows/*.yml   # every one runs from the repo root, e.g. ci.yml:3314, :3486, :3576, :3584
$ ls ui/.github
ls: cannot access 'ui/.github': No such file or directory
Reading 2: no workflow reads ui/lychee.toml
$ git grep -n 'lychee' -- ':!ui/CHANGELOG.md' | grep -v '^content/docs/releases' | grep -v '^.github/workflows/check-links.yml'
ui/lychee.toml ... (its own text)
ui/scripts/__tests__/check-links-workflow.test.ts ...
scripts/check-adr-links.mjs / scripts/check-doc-anchors.mjs (prose naming the ROOT lychee.toml)
$ sed -n 120,126p .github/workflows/check-links.yml
        --root-dir ${{ github.workspace }}/content
        --fallback-extensions mdx,md
        --config lychee.toml
Reading 3: probe, the live config substituted for the parked one (base 4d3a077, restored by hash)
parked tasks: build test test:dist test:watch lint //#lint:root type-check //#type-check:e2e clean dev
DIFF build.inputs: onlyParked=["$TURBO_ROOT$/tsconfig.json","$TURBO_ROOT$/scripts/vite-*.ts","$TURBO_ROOT$/scripts/build-plugin-stylesheet.mjs","$TURBO_ROOT$/scripts/check-dist-completeness.mjs","$TURBO_ROOT$/scripts/invoked-as.mjs","$TURBO_ROOT$/scripts/vitest-invocation-guard.mjs"]
DIFF test.inputs: onlyParked=["src/**", ..., "$TURBO_ROOT$/vitest.config.mts", "$TURBO_ROOT$/vitest.setup.*", ...]
MISSING in live: //#lint:root
MISSING in live: //#type-check:e2e

$ vitest run (the 11 reader files) with ui/turbo.objectui.json := JSON of uiScopedTurboConfig()
 Test Files  8 failed | 3 passed (11)
      Tests  147 failed | 294 passed (441)
 per file: turbo-task-guard-coverage 55 · turbo-test-inputs 41 · turbo-build-inputs 38 · turbo-lint-inputs 5 (all in the //#lint:root describe) · e2e-type-check 4 · select-type-check-scope 2 · check-dist-completeness 1 · turbo-build-outputs-cover-published-entries 1
 green: turbo-type-check-inputs, workspace-root, check-links-workflow
Reading 4: derived gates on head 88bd2bb
$ node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack   # 18 families, change set vs merge base 1287b2fa3
node scripts/check-closing-keyword-parity.mjs :: exit 0
node scripts/check-closing-keyword-parity.mjs --self-test :: exit 0
node scripts/check-comment-mask-corpus.mjs :: exit 0
pnpm --dir ui exec vitest run scripts/ :: exit 0
pnpm check:cross-package-test-inputs :: exit 0
pnpm check:driver-memory-census :: exit 0
pnpm check:engine-double-contract :: exit 0
pnpm check:gitlink-declared :: exit 0
pnpm check:nul-bytes :: exit 0
pnpm check:published-files :: exit 0
pnpm check:query-options-erasure :: exit 0
pnpm check:refd-timer-probe :: exit 0
pnpm check:tier-file-adoption :: exit 0
pnpm check:type-check-coverage :: exit 0
pnpm check:type-check-debt :: exit 0
pnpm check:undeclared-dep-imports :: exit 0
pnpm check:watch-hint-literal :: exit 0
pnpm check:where-matcher :: exit 0

$ node scripts/pm/dispatch-gates.mjs --repo objectstack-ai/objectstack --ran ran.txt
✓ dispatch-gates --ran: 18 derived famil(ies) accounted for — 18 run, 0 NOT-MEASURED (a DERIVED zero — all 18 recorded an exit code and none of them is 3).

🤖 Generated with Claude Code

https://claude.ai/code/session_01QSeKYmTYfaPbLQD4BJfomW


Generated by Claude Code

…e remap pin read the config that runs

No turbo invocation in this repository reads ui/turbo.objectui.json and no
workflow reads ui/lychee.toml: every `turbo run` resolves the root turbo.json,
and check-links.yml passes the root lychee.toml. The guards whose property the
root files carry now read them: `type-check` and package `lint` inputs through
uiScopedTurboConfig, and the no-remap pin against the root lychee.toml. The
guards whose property the root config does not carry keep reading the parked
copies, unchanged, so both files stay.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QSeKYmTYfaPbLQD4BJfomW
@objectstack-fleet objectstack-fleet Bot added the skip-changeset PR has no user-facing published change; bypasses the changeset gate label Oct 28, 2026
…lete the unread ui/lychee.toml

The pin held objectui's root_dir sentinel in ui/lychee.toml, a file no
workflow reads. The lane that runs, the root check-links.yml, resolves
site-absolute routes with --root-dir at the content root plus
--fallback-extensions, so the pin now reads that argv: the root lychee.toml
config, an absolute --root-dir over the tree /docs routes live under, and the
mdx/md fallbacks. With its last reader retargeted, ui/lychee.toml goes.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QSeKYmTYfaPbLQD4BJfomW
@github-actions github-actions Bot added size/m and removed size/s labels Oct 28, 2026
@objectstack-fleet objectstack-fleet Bot changed the title test(ui/scripts): the type-check and lint inputs guards and the lychee remap pin read the root configs that run; both parked configs stay test(ui/scripts): the inputs guards and the lychee pins read the configs that run; ui/lychee.toml is deleted, ui/turbo.objectui.json stays Oct 28, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:devx#2 · os-justin · session_01QSeKYmTYfaPbLQD4BJfomW

席位核对 — ACCEPT · domain:devx#2 · head 88bd2bb7e1 · 2026-10-28T14:56Z

维护者速读

  • 改了什么:先实测确认 ui/turbo.objectui.json 和 ui/lychee.toml 都是死配置:仓库合并以后没有任何真实的 run 再读它们。随后把能改的守卫改成读真正生效的配置:type-check 输入守卫、包级 lint 输入守卫、lychee 的两条守卫(站内路由那条改为直接读 check-links.yml 的 lychee 参数)。ui/lychee.toml 已经没有读者,本 PR 把它删了。
  • 为什么改:守卫对着一份没人用的配置断言,永远是绿的,什么也没守住,属于假绿。
  • 风险与回滚:只改 ui/scripts/__tests__ 下 4 个测试文件,外加删 1 份死配置;不碰运行时、构建配置、workflow 和任何发布包。回滚 = 还原本 PR。
  • 先看:check-links-workflow.test.ts 里新的站内路由守卫,以及 helpers/turbo-inputs.ts 的 liveTurboConfig()。
  • 两分钟验证:pnpm --dir ui exec vitest run scripts/,全过(174 个文件、5003 条)。
  • 需要你做的:无,席位落地。dev 实测发现根 turbo.json 的 ui 构建输入有缺口,可能回放旧的构建产物,席位已另立卡 [devx] root turbo.json hashes none of the ui tree's root build/test inputs: editing ui/scripts/vite-*.ts or ui/tsconfig.json can replay a stale @object-ui/* build from cache #27283 跟进;ui/turbo.objectui.json 也随那张卡一起删。

席位意见:合入。实测在前,改动只把守卫改指到真正运行的配置,断言一条没放宽;改不了的 147 条原样保留,挪到 #27283 处理。lychee 的新守卫,删 --root-dir 或 --fallback-extensions 任一个都会变红,dev 逐个验证过。

Shape: draft → main, Part of #26080 (slice 2). 5 files, +99/−148: ui/lychee.toml deleted, plus check-links-workflow.test.ts, helpers/turbo-inputs.ts, turbo-type-check-inputs.test.ts and turbo-lint-inputs.test.ts. Label skip-changeset, assignee os-justin. Not governed. Claim 6469923805; reports 6471544589 and addendum 6472282515. The seat patched the PR body and title from the addendum's pr_body_changes_for_the_seat.

Premise measured (dev, in the PR body's readings): no turbo invocation reads the parked file. Turbo resolves the root turbo.json plus ui/apps/console/turbo.json, and no --root-turbo-json is passed. check-links.yml passes the root lychee.toml.

Seat's own read:

  • The new site-route pin parses check-links.yml env.LYCHEE_ARGS. This is a read only; no workflow line changes. It asserts --config lychee.toml, a workspace-anchored --root-dir whose tree holds docs/, and --fallback-extensions ⊇ {mdx, md}. That is the both-halves property the old sentinel pin held, restated for the mechanism that runs. Teeth: removing either flag on disk turned it red with its own message, and the file was restored by hash.
  • taskInputs/rootAnchoredInputs default to the parked copy, so every guard not listed as retargeted reads exactly what it read before. No assertion moved.

Gates: on head 88bd2bb7e1, 59 check-runs: 44 success, 15 skipped, 0 failure, mergeable_state: clean. check-expected-skips --pr 27281: OK. check-governed-merges: NOT governed, 247 lines. Dev's union: 18 derived families, all exit 0. ui scripts/ 174 passed | 2 skipped, 5003 tests.

Open questions, answered by the seat: OQ3 → A, done in this PR. OQ1 and OQ2 → filed as #27283 (p2 bug, pm:blocked on this PR). That card carries the root turbo.json ui-input gap, the 147 parked-copy assertions and the deletion of ui/turbo.objectui.json.

Out of scope: the ui/apps/console/turbo.json outputs drift → noted in the PR, no carrier needed (console emits neither path). Skills-docs: none.

Landing: the seat readies the PR and arms auto-merge in this act. On merge, the seat verifies the merged diff, posts the landing note on #26080, archives cloud session session_01QSeKYm6a7FAA3rBWrMCCij and unblocks #27283.


Generated by Claude Code

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review October 28, 2026 14:57
@objectstack-fleet
objectstack-fleet Bot enabled auto-merge October 28, 2026 14:57
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Oct 28, 2026
Merged via the queue into main with commit 0e205fe Oct 28, 2026
60 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-26080-parked-configs branch October 28, 2026 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/m skip-changeset PR has no user-facing published change; bypasses the changeset gate tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants