Repository navigation
feat(app-shell): select loose items on Studio's cross-package list and move them into a package; the Packages page counts them (#38150 PR-A2) - #38389
Conversation
…d move them into a package; the Packages page counts them (#38150 PR-A2) Claude-Session: https://claude.ai/code/session_01L9qibyHmxFV4bTFZ5BKnUz Co-authored-by: Claude <noreply@anthropic.com>
… the select column has a header (#38150 PR-A2) Claude-Session: https://claude.ai/code/session_01L9qibyHmxFV4bTFZ5BKnUz Co-authored-by: Claude <noreply@anthropic.com>
…-j4n4b0 # Conflicts: # ui/packages/app-shell/src/views/metadata-admin/ResourceListPage.tsx # ui/packages/app-shell/src/views/metadata-admin/metadataListState.ts
…nt load at collection (#38150 PR-A2) Claude-Session: https://claude.ai/code/session_01L9qibyHmxFV4bTFZ5BKnUz Co-authored-by: Claude <noreply@anthropic.com>
…t a clickable span The click-without-keyboard census counts a span with an onClick as a new clickable non-control. The guard now sits on the checkbox, a real button. Claude-Session: https://claude.ai/code/session_01L9qibyHmxFV4bTFZ5BKnUz Co-authored-by: Claude <noreply@anthropic.com>
|
repo:objectstack#3 · os-tesla · session_01L9qibwSEecrzDjKjbk24r1 L1-a: ACCEPT for PR #38389 ( Scope. 15 files, +1369 −11, all under Declarations.
Code read against the A1 door.
Nits (non-blocking):
Evidence (
CI at this head: 46 success, 15 expected skips, 0 failed, 1 pending ( K = 35, over the hold of 15. Landing waits on a merge of |
|
repo:objectstack#3 · os-tesla · session_01L9qibwSEecrzDjKjbk24r1 Contract reviewServed-tier: PR #38389, card #38150 PR-A2. Claim 7234216673, amendment 4 7239673373, and the dev report at Why TIER_DEFAULT. The only face is the declaration. The 15 files hold no ① Derived judgments
② Semver level
③ Boundary flags
No must-fix, no should-fix. Implemented-by: VERDICT: PASS |
|
repo:objectstack#3 · os-tesla · session_01L9qibyUSf2nKJWW6qBemSU Recorded 2026-11-29T04:10Z. 维护者速读
席位意见:可以合。 席位核对 — ACCEPT · repo:objectstack#3 · head
|
|
repo:objectstack#3 · os-tesla · session_01L9qibyUSf2nKJWW6qBemSU The seat asked the maintainer to approve this PR through os-zhuang (card note 7250508525: the hand-off tool reads the PR alone as not governed, and the card total puts it at Tier H). Maintainer (Tesla), verbatim, 2026-11-29 04:40:53Z (cmsg_01AXsQkLFKRdQCqQ3RTr6JaoP3EHfyZZcrM6Ek3R1v9Zc6): 「38389 你可以直接合并」 Reading: the seat lands #38389 itself, without an os-zhuang review. The seat record ACCEPT 7250496290 stands. The order is: merge main into the branch (K was 35), let CI go green at the new head, confirm the merge added nothing to the PR's own diff, then |
|
repo:objectstack#5 · os-project-manager · session_01FEkQ5pc3eJbLUEYRBLjxn5 Recorded 2026-11-29T06:07Z. 席位核对 — ACCEPT · repo:objectstack#5 · head
|
|
repo:objectstack#5 · os-project-manager · session_01FEkQ5pc3eJbLUEYRBLjxn5 Landing at 2026-11-29T06:07Z · head
State: draft → ready, auto-merge armed (merge queue). |
…objectstack-ai#38501) <!-- claude-projects-attribution: {"github_login":"os-project-manager"} --> _Requested by **Leehom** · [project thread](https://claude.ai/code/project/chan_01TenzsRopZj4jMbvjX8uz1X?thread=cmsg_01TenzsRopZj4jMbvjX8uz1XK9aBD2HT65noa4cJe7UCLN)_ Fixes objectstack-ai#38392 Clause-②: no Metadata-protocol: none ## 维护者速读 - 用户能看到的变化:搭建者从 ⌘K、应用里的「在 Studio 中设计」、空菜单的「在应用搭建中打开」、设置 → 软件包这几个入口打开软件包时,以前先到对象列表,现在先到「概览」页。 - 为什么做:按你对「所有入口都先进概览页」的决定(App Studio 概览页这条线的收尾),让每个入口落在同一个页面。 - 出错会怎样:最坏是某个入口仍落在对象列表或概览页,不丢数据;对象列表的地址照常可用,可以直接撤回本改动。 - 要你做的:无。 ## What changes Every door that opens a package's Studio now builds `studioPackageOverviewPath` (`/studio/PKG/overview`) instead of `studioHomePath` (`/studio/PKG/data`, the object list). Ruling record 7247357556 on objectstack-ai#37958 (maintainer 「OK」 to 「⌘K、应用里的「在 Studio 中设计」、空菜单和设置页这几个入口,现在打开的还是对象列表。要不要都改成先进概览页?」). Door census on main `d89d3e23` (every non-test caller of `studioHomePath` under `ui/packages/app-shell/src`, measured by grep and now held by the new census test): | Door | Where (symbol) | Before | After | |:---|:---|:---|:---| | 1. ⌘K package entries | `CommandPalette.tsx` `useStudioPaletteEntries` | `/studio/PKG/data` | `/studio/PKG/overview` | | 2. An app's Design in Studio | `appRoute.ts` `appStudioDesignPath`, also the bare-app / `system` / interface-list fallback of `appStudioRoutePath` (AppHeader, ShellPageActions, PageView) | `/studio/PKG/data` | `/studio/PKG/overview` | | 3. Empty menu "Open in App Studio" | `AppNoAccessEmptyState.tsx` (`app-empty-menu-open-studio`) | `/studio/PKG/data` | `/studio/PKG/overview` | | 4. Setup → Packages detail "Open in Studio" | `PackagesPage.tsx` (`pkg-detail-open-in-studio`) | `/studio/PKG/data` | `/studio/PKG/overview` | | 5. Setup → Packages landing after New Package | `PackagesPage.tsx` `CreatePackageDialog` `onCreated` | `/studio/PKG/data` | `/studio/PKG/overview` | | 6. Setup → Packages customizations "Customize in Studio" | `PackageCustomizationsPanel.tsx` (`pkg-detail-customize`) | `/studio/BASE/data` | `/studio/BASE/overview` | - `PackagesPage.tsx` loses its local `const studioPackagePath = (id) => studioHomePath(id)`, which shadowed the exported builder of the same name. - Docblocks that still said the object list (`appRoute.ts`, the palette's Studio entries, the empty state, the customizations panel, `studioHomePath` in `studioAddress.ts`) now say 概览. - `/studio/PKG/data` stays a working address for anyone who wants the object list; `studioHomePath` keeps its builder and route. - Not changed, deliberately: `setupMetadataRedirect.ts` (a retired Setup bookmark that lands on the objects it named, not a door); the pair's bare `/studio/BASE.custom`, which already lands on its base's 概览 since objectstack-ai#38318; and the copilot / MCP review link `studioChangesReviewPath` (`/studio/PKG/data?changes=review`), see Acceptance notes. - Copy: the empty menu's description ("Create objects for this app in App Studio and they join its menu, or add entries in Design layout."), "Open in App Studio" and "Open this app in App Studio, where its items are customized" all stay true on 概览, so no string changes and no locale file is touched. ## ADR-0084 row owed (ask 3) Proposed text for the lander's ADR revisions row (objectstack-ai#38438), to be added under ADR-0084's 2026-11-28 amendment, item (3): > *(Amended 2026-11-29, card objectstack-ai#38392, ruling record [comment 7247357556](objectstack-ai#37958 (comment)), the maintainer's 「OK」 to 「⌘K、应用里的「在 Studio 中设计」、空菜单和设置页这几个入口,现在打开的还是对象列表。要不要都改成先进概览页?」: one landing for every door is ruled. Every door that opens a package's Studio lands on `/studio/PKG/overview`, not on the object list: the command palette's (⌘K) package entries, an app's design-in-Studio entry (`ui/packages/app-shell/src/utils/appRoute.ts#appStudioDesignPath`, also the bare-app fallback of `appStudioRoutePath`), the "Open in App Studio" of an app's empty menu, and Setup → Packages' "Open in Studio", its landing after New Package and its customizations section's "Customize in Studio". The pair's bare address `/studio/BASE.custom`, landed by objectstack-ai#38318, lands on its base's 概览 and is covered by this ruling. `/studio/PKG/data` stays a working address for the object list.)* ## Tests - Re-pointed every pin of the old targets to `/overview`: `appRoute.test.ts` (door 2, five assertions), `CommandPalette.studioScope-11863.test.tsx` and `StudioPaletteGroups.surfaceScope-36900.test.tsx` (door 1), `AppNoAccessEmptyState.emptyMenu-36748.test.tsx` (door 3), `PackagesPage.installedAppsUpdates-34722.test.tsx` (doors 4, 5 and 6), `PackageCustomizationsPanel.test.tsx` (door 6), and the create harness in `PackageFormDialog.newAppStep-36748.test.tsx` (it mounts `CreatePackageDialog` as Setup → Packages does). - New `studioDoorsOverview-38392.test.ts`: (1) parses every non-test source of `@object-ui/app-shell` and refuses any `studioHomePath` reference outside the two files that mean the object list (an alias counts), with a control that the census sees those two; (2) one case per door (6) that finds the door's own `studioPackageOverviewPath(...)` call inside the element, function or handler that is the door. <details><summary>Local readings at head 7be2d5f (worktree off main d89d3e2)</summary> - Build closure `pnpm turbo run build --filter='@object-ui/app-shell^...' --concurrency=2`: 72/72 tasks, lock VERDICT command-exit 0. - Door and pin files (12 files, incl. `studioAddress*.test.ts`, `SidebarItemMenu.designFollowsPackagePosture-12615`, `PageView.editInStudioOpensStudio-12540`): Test Files 12 passed (12), Tests 206 passed (206). - Narrowed `@object-ui/app-shell` run, every test file naming a touched door, component or builder (grep for `AppNoAccessEmptyState`, `PackagesPage`, `PackageCustomizationsPanel`, `appStudioDesignPath`, `appStudioRoutePath`, `studioHomePath`, `CommandPalette`, `StudioPaletteGroups` and the door test ids): Test Files 142 passed (142), Tests 1565 passed (1565). Declared narrowing: the whole package (2462 test files) is left to CI's Test UI; `vitest related` over the changed sources ran out of heap at 4096 MB building the import graph. - `pnpm --filter @object-ui/app-shell run type-check` (src and `tsconfig.test.json`): lock VERDICT command-exit 0. - Ablation 1 (palette door rewritten to the object list on disk, `scripts/ablation-replace.mjs`): the census door case and `CommandPalette.studioScope-11863` "opens a package on its 概览 Overview" both red (`expected '/studio/com.acme.hr/data' to be '/studio/com.acme.hr/overview'`); restored, blob equals HEAD. - Ablation 2 (a `studioHomePath` alias added to `PackagesPage.tsx`): census case 1 red, naming the two references; restored, blob equals HEAD. - Derived gate families (`dispatch-gates --commands`, 40): all exit 0; `--ran` reconciliation "40 derived, 40 run, 0 NOT-MEASURED, 0 UNRUN" (a derived zero, every exit recorded). Also `pnpm --dir ui run check:new-line-citations`: 0 new citations. </details> ## Acceptance notes - Missed by the PM census, not changed here (out of this card's file surface, and a shared server contract): the copilot's "review changes" link `studioChangesReviewPath` builds `/studio/PKG/data?changes=review`, and the server prints the same address (`packages/types/src/studio-review-links.ts`, used by the MCP authoring tools and `os meta register --draft`). It opens the Changes drawer over the object list. Whether that link is a "door that opens a package's Studio" under the ruling is put to the seat in the report; 概览 has a Pending tab (`?tab=pending`) that could be its target. - Out of scope: `studioChangesReviewPath` (the review-changes deep link) is unchanged (seat reading, 2026-11-29T06:12Z: not a door under ruling 7247357556, no new card). - Overlap: `node scripts/pm/overlap-check.mjs` reports a textual conflict with objectstack-ai#38389 in `PackagesPage.tsx`: objectstack-ai#38389 inserts an import directly after the `studioHomePath` import line this PR replaces. One-line resolution for whichever lands second (keep both imports). - `SidebarAppMenu.tsx` reads `appStudioDesignPath` only to gate Design layout on the package's posture (`useStudioEntryGate` reads the package id off the path); it never navigates there, and `studioPathPackageId` parses the `/overview` path the same way (`SidebarItemMenu.designFollowsPackagePosture-12615.test.tsx` green). ## Verification Files to read first, by risk: 1. `ui/packages/app-shell/src/utils/appRoute.ts` — `appStudioDesignPath` is also the fallback of `appStudioRoutePath`, so the app header's bridge moves on the app root, `system` routes and interface lists. 2. `ui/packages/app-shell/src/views/metadata-admin/PackagesPage.tsx` — the shadowing local const removed; both doors now call the builder directly. 3. `ui/packages/app-shell/src/views/studio-design/studioDoorsOverview-38392.test.ts` — the census and its allowlist. Two-minute check: `pnpm --dir ui exec vitest run packages/app-shell/src/views/studio-design/studioDoorsOverview-38392.test.ts` — expect 8 passed. In the running console as a workspace admin: press ⌘K in Studio, pick a package; the address reads `/studio/PKG/overview` and 概览 is shown. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01FEkQ5orhB2g5mxU6E4fciu <!-- signed: repo:objectstack#5 · os-project-manager · session_01FEkQ5orhB2g5mxU6E4fciu --> --------- Co-authored-by: Claude <noreply@anthropic.com>
…onsole entries (objectstack-ai#38150 PR-B1) (objectstack-ai#38545) <!-- claude-projects-attribution: {"github_login":"os-project-manager"} --> _Requested by **Leehom** · [project thread](https://claude.ai/code/project/chan_01TenzsRopZj4jMbvjX8uz1X?thread=cmsg_01TenzsRopZj4jMbvjX8uz1XMRkgb3gwbVL5znx9yxJb7x)_ Part of objectstack-ai#38150. This is PR-B1: the server retirement of `adopt-orphans` and the two console entries that called it. It replaces closed draft objectstack-ai#38364, whose four commits are cherry-picked here onto main after PR-A2 (objectstack-ai#38389, merged as `ea82c96212`), plus the conflict resolution, the re-measured generated outputs and A2's L1 nit N1. PR-B2 (Studio `~org`, the redirects to `?source=loose`, the classifier objectstack-ai#38061, the ADR marks) follows. This PR does not close the card. Clause-②: no (narrowing) Metadata-protocol: narrowed Skills-docs: none (no file under `skills/**` or `.claude/skills/**` names `adopt-orphans`, `adoptOrphans` or "Adopt loose items"; searched at `37aae5aa1`) **Size: 3,387 lines** (additions + deletions, generated files included: 586 added, 2,801 deleted, 79 files; `git diff --numstat origin/main...HEAD` at `37aae5aa1`, merge base `dccf836a8`). With A1's 1,947 and A2's 1,380 the card stands at **6,714**. This PR alone passes 3,000, so it is Tier H. **Metadata-protocol, measured on this head.** `packages/spec/authorable-surface/api.json` loses exactly the four `api/ReassignOrphanedMetadataResponse:*` keys (`reassigned`, `reassignedCount`, `success`, `targetPackageId`) and gains nothing, so the shard moves and the line is `narrowed` (the closed vocabulary has no `removed`). `authorable-surface.base.json` is untouched: only `gen:authorable-surface-base` writes it. ## 维护者速读 - 用户能看到什么变化:软件包页的「收编散落项」按钮和 Studio「⋯」菜单里的同名项去掉了,旧的一次性收编接口改答 404;散落项改用上一个已合并的改动里的「勾选后移入软件包」。移入成功的提示现在写软件包名称,不再写编号。 - 为什么做:App Studio 改版专题的第二步。旧接口一次把全环境的散落项都收进一个包,不走保存时的检查,实测会收进没安装的包、收进前缀不对的对象。 - 出错会怎样:本改动只删东西,外加一处提示文字;出问题最多是某处还引用已删的入口,可以整体撤回。调用旧接口的脚本会收到 404,需要改用新的移入接口。 - 要你做什么:这张卡总行数超过 3000 行,属于需要你本人批准的一档,请审批。 ## Deliberate correction One pending release note, not added by this PR, was made false by it and is corrected in the same stroke: `.changeset/37958-studio-overview-full.md`, line 16. `check-empty-changeset` stays red on it by design (DELIBERATE CORRECTION class); the dispatching seat confirms it by its own record, and the file is not restored. - Before: "- The ⋯ menu keeps "Edit package info", "Duplicate as a new package", "Adopt loose items" and "Manage in Setup…"." - After: "- The ⋯ menu keeps "Edit package info", "Duplicate as a new package" and "Manage in Setup…"." ## What changes **Runtime.** The attribution docblock above `resolvePackageWriteActor` no longer says a body `actor` is ignored on `move-in`: there the strict body refuses it 400 and nothing moves (comment only). The `POST /packages/:id/adopt-orphans` block leaves `packages/runtime/src/domains/packages.ts`, with its mount in `dispatcher-plugin.ts`, its row in `route-ledger.ts` (the census line goes to 157 rows), and `reassignOrphanedMetadata` on the protocol handle type. The route answers 404 (pinned on a booted stack, below). **Protocol.** `ObjectStackProtocolImplementation#reassignOrphanedMetadata` and its facet body in `protocol-package-commits.ts` are removed, and so is `releaseAdoptedObjectOwner` (its only caller was the adoption): the class member, the host entry in `protocol-host.ts`, and the body in `protocol-object-owner.ts`. Comments that named the old door now name the move door, or say it retired. **SDK.** `client.packages.adoptOrphans` is removed from `@objectstack/client`. **Spec.** `ReassignOrphanedMetadataResponseSchema` and its two types leave `package-lifecycle.zod.ts`. The def is registered in `RETIRED_DEFS_BY_MAJOR` (`retired-defs/19.api__ReassignOrphanedMetadataResponse.ts`); its manifest line and shard keys are removed; `api-surface`, `declaration-map`, `export-origins` and the reference docs are regenerated on this base (the reference index now counts 1,741 schemas, 528 in API; main moved the per-module reference page to `packages/spec/docs/references/api/package-lifecycle.md`). `packages_orphan_adoption_unsupported` leaves `operation-message.ts` (four locales). The ADR-0087 disposition is the registered semantic entry `19.packages-adopt-orphans-door-retired.ts`. **Console.** The Packages page's development face loses the "Adopt loose items" button, its dialog, handler and state (`PackagesPage.tsx`); A2's loose-items banner stays as merged. Studio's 「⋯」 menu loses its `adopt` item: on this base (after objectstack#37958 moved Export and the revert to the overview page) `STUDIO_PACKAGE_MENU_ITEMS` is three items, `edit`, `duplicate`, `manage`. With the adoption gone the menu changes nothing a package holds, so its `onChanged` prop and its `run` helper go too, and `StudioDesignSurface` no longer passes `onChanged` to it (`onPackageChanged` still feeds the overview page). `packageActions.tsx` loses `adoptLooseItems`, `adoptedText` and `AdoptLooseItemsDialog`; `@object-ui/i18n`'s studio namespace loses the six `engine.packages.detail.adopt*` keys in en and zh. A2's `engine.looseMove.*` keys are untouched. **N1 (A2's L1 nit).** The move-in success toast filled `{package}` with `answer.targetPackageId` while the confirm title used the package name. `ResourceListPage.tsx` now passes the label the dialog was opened on (`looseMove.target.label`), which is already the id when the package list could not be read. **Docs.** `content/docs/api/metadata-api.mdx`, `protocol/knowledge.mdx` and the system-context register's row 55b name `move-in` where they listed `adopt-orphans`. Left as history: the three spec `18.*` semantic entries, `content/docs/releases/v18/*`, the consumed `.changeset/pre/*` entries, and the historical sentence in `http-dispatcher.ts`. **Changeset.** `38150-adopt-orphans-door-retired.md`, BREAKING with the FROM → TO table and the one-line fix: `@objectstack/spec` major (pre mode), metadata-protocol, runtime, client, `@object-ui/app-shell` and `@object-ui/i18n` patch. One sentence changed from objectstack-ai#38364: the console's move door is now named as "the move-in confirm step on Studio's cross-package list (`?source=loose`), which ships in the same release" (A2 landed first, so "the next change" was no longer true). ## Each removed assertion, and what pins its rule now Deleted files (the old door's own tests): | removed | what it pinned | now pinned by | |:--|:--|:--| | `metadata-protocol/…/protocol.adopt-orphans-owner-judges.test.ts` | the adoption asked the object-owner and permission-set-owner judges | `package-move-in.dogfood.test.ts`: "the object owner: … refused with the save door's mismatch" and "the permission-set owner: …" | | `metadata-protocol/…/protocol.adopt-orphans-platform-record.test.ts` | the platform's own record is not adopted | new facet case in `protocol-package-move-in.test.ts`: "the platform's own record is not loose: refused NOT_LOOSE …", with its control | | `metadata-protocol/…/protocol.reassign-orphans-durability.test.ts` | a refused rebind was logged once while the door answered success | the move door has no partial success; `protocol-package-move-in.test.ts` pins the fault (500, nothing moved) and the failed undo (500 naming what did not go back) | | `objectql/…/protocol-adopt-orphans-draft-view-registry.test.ts` | an adopted draft view reached no registry, before, after and at the next boot; a draft beside an active row served the active body | through `moveIntoPackage`: `package-move-in.dogfood.test.ts` (booted CRM stack) "objectstack-ai#23690: a loose DRAFT view moves as the target's draft, and the registry serves nothing before or after", "objectstack-ai#23690: a draft beside an active row of the same view: the active body is served at the target, never the draft" and "objectstack-ai#23690: at the next boot the moved draft is still served nowhere, and the pair still serves its active body"; and `protocol-package-move-in.test.ts` "a loose DRAFT moves as a draft: saved into the target in draft mode, never published, and answered states [draft]" and "a draft beside an active row: … states [active, draft]" (with an active-only control) | | `objectql/…/protocol-adopt-orphans-object-registry.test.ts` | the registry owner followed an adopted object | `package-move-in.dogfood.test.ts` A3 and "whole or nothing", and `package-first-authoring.dogfood.test.ts`'s D5 case, driven through `moveIntoPackage` | | `runtime/…/packages-adopt-orphans-readonly.test.ts` | the door's gates and their order | the `move-in` rows that replace `adopt-orphans` in the runtime route tables (capability gate, read-only remedy, walled refusal, knowledge-source gate, closed query, vetted org source, partial-host 501 and its message key) | | `ui/…/PackagesPage.adoptLooseItems-13339.test.tsx` | the console's Adopt dialog | the entry is removed; A2's `LooseMoveDialog-38150` and `ResourceListPage.looseMove-38150` pin the replacement | Edited files, as in objectstack-ai#38364 (metadata-protocol, objectql, runtime, client, spec, dogfood, `scripts/engine-double-contract.pinned.json`), with these changes at this head: - `packages-write-actor-session.test.ts`: its `adopt-orphans` row (a body naming another user, a body naming no one, a system context) is replaced by a `move-in` describe: a signed-in caller's move, and its dry run, hand the protocol the session user as `actor`; CONTROL: a system context sends no actor; a body `actor` (another user, or the session user itself) answers 400 `Invalid move-in body` naming the key, and the protocol is never called. - `StudioPackageMenu-37139.test.tsx`: three items (`edit`, `duplicate`, `manage`) in en and zh-CN, not five; the read-only case greys Edit and Duplicate; the adopt action case and the adopt rows of the one-copy list are removed; the guard that no surface spells the `/adopt-orphans` door stays. - `StudioPackageOverview-37454.test.tsx` (added on main by objectstack#37958 after objectstack-ai#38364 was built): the menu pin lists three rows, no adopt row. - `ResourceListPage.looseMove-38150.test.tsx` (N1): "the success toast names the package by its name, as the confirm title does", and its control "when the package list cannot be read the confirm and the toast both fall back to the id". - `package-move-in.dogfood.test.ts`: "the retired all-at-once door is gone: POST …/adopt-orphans answers 404 and moves nothing", and the three objectstack-ai#23690 cases above. - Comments that named the retired entry as live: `protocol.ts` (the object-owner import line) and `package-duplicate-adopt-org-scope.integration.test.ts` (two docblocks). ## Acceptance notes - `overlap-check.mjs` at `37aae5aa1`: clean against main; one textual overlap with open objectstack-ai#38541 in `content/docs/references/index.mdx` (generated; whichever lands second regenerates it with `gen:docs`). The overlap with objectstack-ai#38527 read at the previous head no longer shows. - The claim on objectstack-ai#38150 (7251650149) names the branch `claude/project-thread-j4n4b0` (A2's). This PR is on `claude/project-thread-pf8r6c`, the branch the seat's dispatch for this thread named. ## Verification Files to read first, by risk: 1. `ui/packages/app-shell/src/views/studio-design/StudioPackageMenu.tsx`: the conflict with objectstack#37958 resolved to three rows, with `onChanged` and `run` removed. 1a. `packages/qa/dogfood/test/package-move-in.dogfood.test.ts`: the objectstack-ai#23690 cases and their state fixture (draft rows inserted at the first boot). 2. `packages/runtime/src/domains/packages.ts` and `route-ledger.ts`: the route block and its ledger row. 3. `ui/packages/app-shell/src/views/metadata-admin/ResourceListPage.tsx`: N1's label hunk. Two-minute check: `pnpm --dir ui exec vitest run packages/app-shell/src/views/studio-design/StudioPackageMenu-37139.test.tsx packages/app-shell/src/views/metadata-admin/ResourceListPage.looseMove-38150.test.tsx`. Expect both files to pass, and the menu case to list three items. <details><summary>Suites (local; the package suites ran on the tree before the A2 merge commit `6742ce449`, the spec suite again after it; UI and gates at the heads named)</summary> | suite | result | |:--|:--| | `@objectstack/client` test | 59 files, 828 tests passed | | `@objectstack/spec` test | 913 files, 28,889 passed, 1 todo | | `@objectstack/metadata-protocol` test | 372 passed, 9 skipped files; 23,629 tests passed, 45 skipped | | `@objectstack/objectql` test | 640 files, 14,530 tests passed | | `@objectstack/runtime` test | 655 files, 12,481 passed, 25 skipped | | typecheck: client, spec, metadata-protocol, objectql, runtime | each lock VERDICT command-exit 0 | | UI touched files + `ui/packages/i18n` (8 named files + the i18n dir) | 117 files, 1,988 passed, 13 skipped | | full `@object-ui/app-shell` suite at `6742ce449` | 2,464 files: 2,462 passed, 1 skipped, 1 failed: `StudioPackageOverview-37454` "the ⋯ menu holds … adopt loose items …" (a main pin of the removed row). Fixed in `c9c49d97e`; that file and `StudioPackageMenu-37139` then 2 files, 71 tests passed | | `@object-ui/app-shell` and `@object-ui/i18n` type-check | lock VERDICT command-exit 0 | | `@objectstack/spec check:generated` after the A2 merge | all 14 artifacts current | | `check-platform-checklist --changed-from origin/main` | OK, 54 anchors judged, 0 lost | </details> <details><summary>Round 1 (review FAIL at `c9c49d97e`, M1 and M2), at `448cffe6f` and `37aae5aa1`</summary> - `packages-write-actor-session.test.ts` + `package-duplicate-adopt-org-scope.integration.test.ts`: 2 files, 25 tests passed. Ablation (`scripts/ablation-replace.mjs`, `resolvePackageWriteActor(_context)` before `protocol.moveIntoPackage` replaced by `undefined`, anchor 1 → 0): "a signed-in caller's move hands the protocol the session user" and "so does a dry run" failed, 2 failed and 20 passed (the system-context control and the 400 cases green); restored, blob equals HEAD. - `protocol-package-move-in.test.ts`: 11 passed. `Type Check · workspace` was red at `448cffe6f` on this file's new draft case (TS2532 / TS2493 on the commit read); `37aae5aa1` types it, and `pnpm --filter @objectstack/metadata-protocol run typecheck` (its `tsc` lists this file) and `@objectstack/runtime` typecheck exit 0, the file 11 of 11. Ablation (`mode: state === 'active' ? 'publish' : 'draft'` → `mode: 'publish'`): both draft cases failed, 2 failed and 9 passed; restored, blob equals HEAD. - `package-move-in.dogfood.test.ts`: 24 passed. Ablation of the same line on the built output (mutation held, `@objectstack/metadata-protocol` rebuilt, `ablation-dist-preflight.mjs` found the marker in `dist/`): all three objectstack-ai#23690 cases failed, 3 failed and 21 passed. Restored, rebuilt, preflight `--absent` clean, the file 24 of 24 again. - Derived gates for this round's seven paths (`dispatch-gates.mjs --commands PATHS`): 78 families, 77 exit 0, and `check-empty-changeset` exit 1 on the DELIBERATE CORRECTION above (expected). `--ran`: "78 derived, 78 run, 0 NOT-MEASURED, 0 UNRUN". `check-nul-bytes`: exit 0. </details> <details><summary>N1 ablation</summary> `scripts/ablation-replace.mjs` replaced `looseMove?.target.label ?? answer.targetPackageId` with `answer.targetPackageId` (anchor 1 → 0, blob `90937804f355` → `ed3e458acb2a`): "the success toast names the package by its name" failed (`expected "vi.fn()" to be called with arguments: [ 'Moved into Alpha: 1.' ]`), 1 failed and 8 passed, the control among the passing. Restored: blob equals HEAD, `git diff HEAD` empty. </details> <details><summary>Derived gates</summary> `node scripts/pm/dispatch-gates.mjs --commands` (no paths, change set from the merge base `dccf836a8`): 149 families. All 149 exit 0. Five first answered 99 or 3 (two vitest families queued behind the app-shell suite; `check:skill-examples`, `check:dual-build-cjs-loads`, `check:published-readme-exports` needed `client-react`, `studio` and `scenarios` built) and passed on the re-run after that build. `--ran`: "149 derived, 149 run, 0 NOT-MEASURED, 0 UNRUN". The commands re-derived at `c9c49d97e` give the same 149. </details> <details><summary>Dogfood battery</summary> Full battery at head `448cffe6f`, `pnpm --filter @objectstack/dogfood test` under the verify lock (no shard, no path): lock VERDICT command-exit 0; Test Files 495 passed, 3 skipped (498); Tests 4,187 passed, 68 skipped (4,255); no failure. `37aae5aa1` after it changes one line of a metadata-protocol unit test's typing, which no dogfood file reaches. (The battery at `c9c49d97e`: 495 / 4,184 passed.) </details> ## Owed before landing - CONTRACT_REVIEW_TIER L2 (the seat's). - A dogfood battery from the landing head. - Maintainer approval (Tier H). - Ships in the same version as PR-B2 (seat rule): after approval this PR is not enqueued until B2 is approved too; both enqueue together, with no Version Packages merge between them. 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- signed: repo:objectstack#5 · os-project-manager · session_01FEkQ5pc3eJbLUEYRBLjxn5 --> --------- Co-authored-by: Claude <noreply@anthropic.com>
…and an item of a package you can write reads New in the Studio list (objectstack-ai#38150 PR-B2) (objectstack-ai#38598) <!-- claude-projects-attribution: {"github_login":"zhuangjianguo"} --> _Requested by **Jianguo** · [project thread](https://claude.ai/code/project/chan_018ETKaNwMZCNRYD7D8Q9Ubb?thread=cmsg_018ETKaNwMZCNRYD7D8Q9UbbYYVoMKNg2bko9Bx8v783A8)_ Fixes objectstack-ai#38150 This is PR-B2, the last PR of the card: the retirement of Studio's package-less scope (`/studio/~org`) with its redirects, the Studio list's Source classifier, and the ADR marks. PR-A1 (objectstack-ai#38185), PR-A2 (objectstack-ai#38389) and PR-B1 (objectstack-ai#38545) are merged. It continues the branch `claude/project-thread-kf5k6i` of the seat whose account ran out (five commits, head `2a3c6e8f5b`, no PR was open on it): this branch starts at that head, every commit was read, and main is merged in. Two cards ride on this one and are named here without a closing keyword, because their threads carry no claim naming this branch: the Source-badge card objectstack-ai#38061 (its ruling note names this PR as its carrier) and the old door's defect card objectstack-ai#37468 (the card text gives it to PR-B). The seat finishes both at landing. Clause-②: no (narrowing) Metadata-protocol: none Skills-docs: none — no file under `skills/**`, `.claude/skills/**` or `content/docs/**` names the `~org` scope, "Organization flows" or any of the nine keys (`git grep` at this head) **Size: 2,937 lines** (1,697 added, 1,240 deleted, 82 files; `git diff --shortstat origin/main...HEAD` at `85939f9c`, merge base `301417669`). With PR-A1's 1,947, PR-A2's 1,380 and PR-B1's 3,387 the card stands at **9,651**. The card total is over 3,000 and the diff edits `docs/adr/**`, so this PR is Tier H. ## 维护者速读 - 用户能看到什么变化:Studio 左侧菜单里的「组织流程」入口没有了,旧网址仍能打开并转到跨软件包列表的「散落项」流程列表;在 App Studio 列表里,自己建的软件包里的项,来源从「系统自带」改成「新建」,筛选和上一条、下一条跟着一致。 - 为什么做:这是 App Studio 改版专题第 4 阶段的收尾,你已裁定散落项原地保留、改用「勾选后移入软件包」来移动,旧入口随新入口上线一起下线;来源标签按你对决策稿的回答改。 - 出错会怎样:只有打开旧网址或看这个列表的人会碰到,最坏是老书签落在列表上而不是原来的流程页,或某一行的来源标签显示不对;不动任何数据,可以整体撤回。 - 要你做什么:这次改动带架构决定记录的标注,整张卡累计也超过 3000 行,需要你本人批准,请审批。 ## What changes **The scope is retired, its addresses answer.** `studio-design/studioOrgScopeRetired.ts` is the one owner of the retired segment (`RETIRED_ORG_SCOPE_SEGMENT`) and of where its addresses land (`retiredOrgScopeTarget`): every `/studio/~org/…` address lands on `/studio/~all/metadata/flow?source=loose`, the list the Setup → Packages banner links to. The list's search (`q`) and sort (`sort`) are carried and every other query key is dropped, `source=runtime` included. Four places answer an old address with it: `StudioDesignSurface` (before anything of the surface mounts), `studioPillarRedirectModel.ts` (the scope's root and its old pillar deep links), `metadataArea.ts` (the scope's leg of the area, and a `?package=~org` link on another leg), and the console's `StudioRoute.tsx` (two route rows that answer the segment ahead of the package routes). **What leaves with it.** The menu's "Organization flows" row and its `orgFlows` entry kind; the area's `orgScope` mode; the top-left Changes row (`StudioScopePendingRow`) and the package-less batch publish behind it (`studioSurfacePublish.ts` publishes a package only now; the changes sheet is mounted on a package only); the `scope` prop of the package switcher; the scope helpers in `studioScope.ts` (`studioOrgScopePath`, `STUDIO_ORG_SCOPE_SEGMENT`, `STUDIO_ORG_SCOPE_TYPE`, `STUDIO_ORG_SCOPE_SOURCE`, `isStudioOrgScope`, `isOrgScopeDraft`), `orgScopeFlowOf` and `orgScopeAreaRedirect`. `AutomationsPillar` takes a package id, never `null`. `studioScope.ts` keeps what the Loose list reads: `isPackageLessItem`, `isPackageLessDraft`, and `packageLessItemPath` (an item of no package opens its page at `/studio/~all/metadata/TYPE/NAME`). **Who lands where now.** A person who may enter Studio but not Setup → Packages, with no recent package, lands on the Loose list of flows (`studioEntryFallbackPath`, `newPackageDoorPath`); the "package not found" page's way out reads "Open loose flows" (「打开散落的流程」) and opens the same list. A package-less flow the app's command palette finds opens its item page. A draft of no package is published by Home's "Publish all", or published or discarded on its own page. **The Studio list's Source (the classifier, card What 7).** `metadata-admin/studioListSource.ts`: `studioSourceKind` takes a third, required fact, whether the row's package is one the author can write, read from the package list's `writable` verdict (`useWritablePackageIds`, the request the other readers of that list share). Order: the customization mark, then the package verdict, then the provenance. `ResourceListPage.tsx` passes it to the badge, the source filter and its counts, and the badge's tooltip; `useListOrderedNames.ts` passes it to the detail page's previous / next order and waits for the package list only while the order is narrowed by source. Setup's list is untouched: it asks for no verdict and reads the provenance as served. **i18n (the narrowing).** Nine keys leave the `studio` namespace of `@object-ui/i18n`, in `en` and `zh`: `engine.studio.menu.orgFlows`, `engine.studio.pkg.orgScope`, `engine.studio.org.name`, `engine.studio.org.hint`, `engine.studio.org.description`, `engine.studio.org.none`, `engine.studio.publishedAllFlows`, `engine.studio.publishedAllFlowsOne`, `engine.studio.changes`. `engine.studio.notFound.allMetadata` keeps its key and changes its text. `@object-ui/app-shell` is private; its barrel exports `RETIRED_ORG_SCOPE_SEGMENT` and `retiredOrgScopeTarget` where it exported `STUDIO_ORG_SCOPE_SEGMENT` and `studioOrgScopePath`. **ADR marks (governed, card What 9).** ADR-0084: nine passages that name the scope are struck through and left legible (the "organization's own flows" row of "Entries that are not a type", the no-fold sentence, the first example of the sorting rule's third test, the second sentence of item 3 of the 2026-11-25 silent-points list, the fourth top-bar-homes row with its 2026-11-27 note, the sentence that kept the entry until the door shipped, and two items of the 2026-11-26 silent-points list), with notes dated 2026-11-29 that name the card and the ruling record (comment 7184753035, question 3); the note under "Organization-level content" says the move door shipped, where it opens from, what retired with the scope (the menu row, the scope's list, its flow page, its Changes row and the batch publish behind that row), where a flow of no package opens now, where `~org` addresses land, and that the bulk adopt retired in a change of its own (objectstack-ai#38545). ADR-0070: the status line, a pointer at TL;DR item 5, and a dated note under D5 ("move into a base" is the move-in door; the bulk assignment to a default base is superseded; rows never moved stay legal). No heading anchor changes. **Changeset and checklist.** `.changeset/38150-studio-org-entry-retired.md`: `@object-ui/app-shell`, `@object-ui/console` and `@object-ui/i18n` patch, BREAKING with the nine keys, the two export renames as a FROM → TO table and the one-line fix, and the ADR-0087 `not-required` marker. `docs/qa/platform-checklist/FOLLOW-UPS.md` gains one section naming the five checklist items that still describe the retired scope. ## Each removed assertion, and what pins its rule now Renamed cases (same assertion, the target address or the words changed with the retirement) are not listed: `StudioRoute.test.tsx`, `StudioRoute.recentPackage-11863`, `CommandPalette.studioScope-11863`, `HomePage.noAgentsBuildChip-26614`, `SidebarAppMenu-36112`, `StudioDesignSurface.notFound-26708`, `StudioEntryRedirect.test.tsx`, `studioInterfacesRetired.test.ts`, `studioPillarRedirectModel.test.ts`, `studioMenuModel.test.ts` (its `~org` rows leave the `it.each` tables; the `~all` rows stay), `StudioMenu.test.tsx` and `StudioMenu.overview-37454` (the last two drop their `~org` row the same way). The others now expect `/studio/~all/metadata/flow?source=loose` where they expected the scope. | file | removed | what pins the rule now, or why it retired | |:--|:--|:--| | `studioScope.test.ts` | "the reserved segment cannot name a package" (the spec manifest-id rule, the sanitizer) and "is told apart from a package segment" | moved with the segment to `studioOrgScopeRetired.test.ts`: "the retired segment stays reserved: it can name no package", the same three cases on `RETIRED_ORG_SCOPE_SEGMENT` and `isRetiredOrgScope` | | `studioScope.test.ts` | `studioOrgScopePath`: "lands on the scope's flow list…", "opens a flow full-screen on its address…" | the builder is removed. The addresses it built are the inputs of `studioOrgScopeRetired.test.ts` "the old addresses, read by the redirects that answer them" (root and `/automations`; list, flow and flow history; a `?package=~org` link). Where a package-less item opens is `packageLessItemPath`, pinned in two new cases of the same file | | `studioScope.test.ts` | "the scope reviews package-less FLOW drafts only" (`isOrgScopeDraft`) | the predicate retired with the Changes row it fed; nothing reads it. `isPackageLessDraft` keeps its case | | `automationsPillarRedirect.test.ts` | "the package-less scope lands on its own leg, with no package and its source filter once" | the scope's `/automations` never reaches this mapping: `studioPillarRedirect` answers it first. Pinned in `studioPillarRedirectModel.test.ts` ("the table covers every retired pillar segment, on a package and on the retired package-less scope") and `studioOrgScopeRetired.test.ts` | | `metadataArea.test.ts` | "`orgScopeFlowOf` names the package-less scope's flow…" | the function is removed (the area draws no scope flow). The rewritten case beside it pins the replacement: "a flow of the retired scope lands on the list, not on the flow, and the list keeps no tab" | | `AutomationsPillar.newSimilar-28567` | "the package-less scope draws no menu" | the flow designer is a package's now (`packageId` is a string) and the scope draws no page; the redirect is pinned in `StudioDesignSurface.packageLessFlows-11553` | | `StudioTopLeft-37456` | "~org with drafts pending: a Changes row…" and its control "none passed: no Changes row" | replaced by "no scope draws a Changes row": `it.each` over a package and no package, expanded and as a rail | | `StudioDesignSurface.publishCount-11807` | the four package-less publish toasts (two drafts, one draft named by label, several named in the description, none pending) | the batch publish they read is removed. Replaced by "its old address, with package-less drafts pending, lands on the Loose list: no publish door, nothing sent, no toast". The package cases of the file are untouched | | `StudioDesignSurface.packageLessFlows-11553` | the scope's own page: lists its flows, offers no create, its empty-list guidance, its page chrome | replaced by "every address of the retired package-less scope lands on the Loose list of flows" (a redirect table, the kept search and sort, the list holding the clone and none of a package's flows, with a control without the filter, and an empty Loose list) and "the Loose list is the retired scope's page" (the row opens the item page; no menu row, no Changes row, no changes sheet, no page under `~org`) | | `StudioDesignSurface.packageLessFlows-11553` | "opens it editable, and an edit saves a draft bound to no package", and the "editable" half of two entries: "the measured link, through the showcase pillar: lands on the package-less scope, the clone open and editable" and "from that read-only package, a switch into the package-less scope opens it editable" | the scope's flow page is retired, and the door the ruling keeps open for that save (comment 7184753035, question 2) is the clone's item page on the cross-package leg. Pinned by the new "the item page opens writable, and an edit saved there writes a draft naming no package", run over two entries, the page's own address and a read-only package's address that names the clone: the designer's add controls are drawn and Save waits only for an edit; the save is `mode: 'draft'` with no `packageId`, and the item's own publish that follows names none either. It sits in the describe "a package-less flow is edited, and its draft published or discarded, from its item page" | | `StudioDesignSurface.packageLessFlows-11553` | "the package-less scope reviews and publishes exactly its own drafts": the Changes row count, the sheet and its filter, "publishes each package-less flow draft by reference, and nothing through the package batch door" | the row, the sheet and the batch are removed. A package-less draft's two publish paths are pinned by two new cases of "a package-less flow is edited, and its draft published or discarded, from its item page" (Publish and Discard on the item page name no package) and by the unchanged `usePublishAllDrafts.refusal-11922` ("records the batch's health and goes on to the package-less drafts") for Home's Publish all | | `StudioDesignSurface.packageLessFlows-11553` | deep links: "in the package-less scope: the named flow, though another is listed first", "the measured miss: the package-less page, a link naming a packaged flow", "an empty scope lands on its list" | the scope has no page to miss on. "the measured link, through the showcase pillar" now lands on the clone's item page on the cross-package leg, and "the package's own address naming the clone lands there too" is new; "a package page's miss" stays | ## Acceptance notes - **Takeover.** Kept as built: the five commits of `claude/project-thread-kf5k6i` (`db6e4a61`, `94ca83cb`, `51d85a2c`, `31121663`, `2a3c6e8f`), read hunk by hunk. Added here: the merge of main (`c03f1772`, clean, eight files auto-merged, PR-B1 among main's commits) and one comment-only commit (`5fcf89b5`): eleven files of the Studio surface still described the retired scope as a place a person can be (the palette surface's doc, four notes in `studio-design`, six test headers or titles). No behaviour changes in it. - **Rework round 1** (L2 record 7257159073, FAIL on `5fcf89b5`; L1 record 7257170665, REWORK). Three commits, no product code in them. **M1**, `c2ffeaa7`: `ui/e2e/studio-left-menu-36899.spec.ts` still waited for the fold's Automation group, whose one row on that package was the retired entry; the loop reads `system` and `security`, the Automation group is asserted absent, and the line names the card. **S1**, `90713851` and `85939f9c`: the item-page case of the table above. **N1 and N2**, `90713851`: ADR-0084's sorting rule (third test) and item 3 of the 2026-11-25 silent-points list are marked, and the note under "Organization-level content" lists the scope's flow page. **N4 is left as it is**: narrowing `sourceNarrowed` in `useListOrderedNames.ts` moves product code for one request and a short wait on the Loose list's previous / next, with no wrong order, and would owe the battery again; it fits the follow-up card the seat files for N3. **N3** is the seat's to file. The delta contract review of `85939f9c` is record 7257925349 (PASS: M1, S1, N1 and N2 closed), and the seat's record 7257936891 accepts the head. - **File surface.** All 82 changed files are inside the claimed surface. One, `ui/e2e/studio-left-menu-36899.spec.ts`, is admitted by claim amendment 7257086821 (one hunk). The other 81 are inside claim amendment 2 (comment 7253593955): 58 under `studio-design/`, 5 under `metadata-admin/`, the console's `StudioRoute.tsx` and four of its tests, `CommandPalette.tsx` and its `~org` test, `index.ts`, `README.md`, three tests pinning `~org` under `console/home`, `layout` and `views/setup`, the two studio catalogues, the two ADRs, the changeset, and `FOLLOW-UPS.md`. - **Clause-②, measured as the amendment asks.** The nine keys are in the published `@object-ui/i18n@19.0.0-next.2` (`dist/namespaces/studio/en.js` and `zh.js`, each key in both files; read from the registry tarball) and in no file of the `dist` built at this head, where two kept keys (`engine.studio.notFound.allMetadata`, `engine.list.source.new`) are in both files. Published keys leave, so the line stands. - **Card acceptance, PR-B under Q-f = E.** "On `/studio/~all/metadata/flow` the authored package's flow reads 新建 and a code-shipped flow still reads 系统自带": `ResourceListPage.authoredPackageSource-38150` "the authored package's flow reads New; the code-shipped flow still reads System-shipped" and "draws the Chinese words for the two". "The Studio filter and prev/next agree with the badge": the three cases under "the source filter and ‹ › agree with the badge". The ablation is below. "`/studio/~org/…` redirects": the redirect tables in `studioOrgScopeRetired.test.ts`, `StudioDesignSurface.packageLessFlows-11553` and the console's `StudioRoute.metadataArea-28561`. - **Premise check of What 7.** No non-test `source=runtime` address remains: `git grep` for it over `ui/packages`, `ui/apps` and `packages`, tests and changelogs excluded, has zero hits at this head. - **"Rechecked in PR-B".** From the Setup → Packages banner a person reaches the flow's Loose list: the banner's link and every `~org` address are one address, pinned by "is the Loose list of flows, the address the Setup → Packages banner links to". A package-less flow draft is published from its item page (two new cases) and from Home's Publish all (unchanged `usePublishAllDrafts.refusal-11922`), and an edit of a loose flow is saved in place from that page (the two-entry case). This recheck is at the test level. A console walkthrough in a browser was not run for this PR: NOT MEASURED, reason: the card asks the walkthrough of PR-A, and nothing here adds a screen. - **Left alone, outside the claimed surface.** Comments that still name the scope in `preview/DraftChangesPanel.tsx` (two) and three test titles beside it, in `ui/packages/i18n/src/__tests__/confirmNoteSeparate-11591.test.ts`, and in `metadata-admin/metadataAreaHost.ts`, whose `emptyListHint` option has no producer left while `ResourceListPage.tsx` still reads it. Named in the report for the seat. - **Same-version rule.** PR-B1 merged at 2026-11-29T11:44Z and is unreleased; the open Version Packages PR is objectstack-ai#38192. This PR has to merge before that one does. Nothing on the dev side blocks it; it waits on the reviews below. ## Verification Files to read first, by risk: 1. `ui/packages/app-shell/src/views/metadata-admin/studioListSource.ts`, with its two readers in `ResourceListPage.tsx` (`studioKindOf`, the badge tooltip) and `useListOrderedNames.ts`: the one behaviour change that is not a removal. The risk hunk is the order in `studioSourceKind` (mark, then package verdict, then provenance) and the `loading` wait in the previous / next order. 2. `ui/packages/app-shell/src/views/studio-design/studioOrgScopeRetired.ts` and the four places that answer an old address with it (`StudioDesignSurface.tsx` line 130, `studioPillarRedirectModel.ts`, `metadataArea.ts`, the console's `StudioRoute.tsx`): what a retired address keeps and drops. 3. `docs/adr/0084-application-builder-information-architecture.md` and `docs/adr/0070-package-first-authoring.md`: the governed text. Struck lines and dated notes only. Two-minute check: `pnpm --dir ui exec vitest run packages/app-shell/src/views/studio-design/studioOrgScopeRetired.test.ts packages/app-shell/src/views/metadata-admin/ResourceListPage.authoredPackageSource-38150.test.tsx`. Expect two files and 25 tests to pass; the second file's first describe is the classifier's truth table. <details><summary>Suites and type checks (local; heads named per row)</summary> | run | head | result | |:--|:--|:--| | workspace build, `turbo run build` without the docs app, under the verify lock | `c03f1772` | 123 tasks, 123 successful; lock VERDICT command-exit 0 | | 714 UI test files under the lock: all of `studio-design/`, `chrome/`, `views/setup/`, `console/home/`, `preview/` and `packages/i18n/`, every test that imports a changed module or names `ResourceListPage`, `StudioDesignSurface`, `StudioMetadataArea` or `DraftChangesPanel`, and the console's `StudioRoute*` tests | `c03f1772` | Test Files 714 passed (714); Tests 7,423 passed, 13 skipped (7,436); lock VERDICT command-exit 0 | | the ten files the comment commit or an ablation touched, again | `5fcf89b5` | Test Files 10 passed (10); Tests 181 passed (181); lock VERDICT command-exit 0 | | `type-check` of `@object-ui/app-shell`, `@object-ui/console`, `@object-ui/i18n` (each covers its test files) | `5fcf89b5` | all three executed, none from cache; lock VERDICT command-exit 0 | | `eslint` on the changed files of the three packages (69, 5 and 2 files) | `5fcf89b5` | 0 errors | The full `@object-ui/app-shell` suite (2,470 files) was not run: NOT MEASURED locally, reason: the dev contract keeps a card to the affected files; CI's Test UI shards run all of it. `5fcf89b5` changes comments and one test title, so the 714-file reading at `c03f1772` stands for it. The rework changes one of those 714 files, run whole again at `85939f9c` (the rework block below). </details> <details><summary>Ablations</summary> Both through `scripts/ablation-replace.mjs`, the implementation committed first, each restored and proven (blob equals HEAD, `git diff HEAD` empty). - **The classifier.** Deleted `if (inWritablePackage) return 'new';` from `studioListSource.ts` (anchor 1 → 0, blob `187ff2023a0e` → `cb5b1ba68bdc`), then ran `ResourceListPage.authoredPackageSource-38150`: 9 failed, 5 passed (14). Red: the truth-table case (`expected 'system' to be 'new'`), the badge in en and zh, the tooltip, the two filter cases, the previous / next case, the authored package's own leg, and the control "a package the list does not name, and no package at all, read as before" (it fails in the shared settle step, which waits for the authored row to read New; its own two assertions do not read the deleted line). Green: "only a package list that was read names a writable package", the two unreadable-package-list controls, and the two Setup controls. - **The surface's redirect guard.** Deleted the `isRetiredOrgScope` line of `StudioDesignSurface.tsx` (anchor 1 → 0, blob `77a97116460c` → `e3360209ed14`), then ran `StudioDesignSurface.packageLessFlows-11553`, `StudioPackageOverview-37454` and `StudioDesignSurface.publishCount-11807`: 3 failed, 93 passed (96). Red: the redirect-table row for the scope's area address with extra query keys, "draws no menu row for the retired scope, no Changes row, no changes sheet, and no page under `~org`", and "~org/overview redirects to the Loose list of flows (the surface alone: its own guard)". The other rows stay green because the pillar redirect answers them first, which is the two-door shape the tests name. </details> <details><summary>Derived gates and the lanes the derivation does not list</summary> `node scripts/pm/dispatch-gates.mjs --commands` (no paths; 81 paths against merge base `301417669`): 49 commands, the same 49 at `c03f1772` and at `5fcf89b5`. Run at `5fcf89b5`, each recorded with its exit code: all 49 exit 0. `--ran`: "49 derived, 49 run, 0 NOT-MEASURED, 0 UNRUN". With the Playwright spec added the derivation is the same 49 (read at `c2ffeaa7`); what was run again after the rework is in the rework block below. The body gates among them (`check-changeset-no-major`, `check-adr-0087-registration`, `check-closing-keyword-parity`) read this body through a local event file; `check-partof-closing-keyword` read it too: exit 0, and `--body` binds one closing declaration, the card's. Not in the derived list, run by hand at `5fcf89b5`: - 19 gates of CI's Type Check UI and Lint UI lanes, each `pnpm --dir ui run NAME`: `check:i18n-keys`, `check:i18n-drift`, `check:unreferenced-sources`, `check:self-import`, `check:phantom-deps`, `check:esm-specifiers`, `check:spec-symbols`, `check:vi-mock-specifiers`, `check:vi-mock-inherit`, `check:vi-mock-override-shape`, `check:test-path-roots`, `check:control-bytes`, `check:shell-escape-residue`, `docs:check-links`, `check:doc-fences`, `check:doc-types`, `check:handler-key-reads`, `check:metadata-write-doors`, `check:doc-example-readers`: all exit 0. - `pnpm check:changeset-fixed`, `pnpm check:i18n-stale-fill`, `pnpm check:published-readme-exports`, `pnpm check:pm-governed-prose`, `node scripts/docs-audit/check-affected-docs.mjs`: exit 0. `node scripts/check-platform-checklist.mjs --changed-from origin/main`: OK, 2 anchors judged, 0 lost. - NOT MEASURED locally: `check-single-claim-paths` and `check-closing-target-claim` (both need the pull request's number). CI's `PR-body guards (claim · duplicate · Part-of · single-writer path)` concluded success on `5fcf89b5`. </details> <details><summary>Rework round 1 (heads `c2ffeaa7`, `90713851`, `85939f9c`)</summary> | run | head | result | |:--|:--|:--| | CI's red, reproduced: `pnpm exec playwright test e2e/studio-left-menu-36899.spec.ts --project=chromium` from `ui/` | `5fcf89b5` | 1 failed, 3 passed: `studio-menu-advanced-group-automation` not found at line 225, as in CI's `Build & E2E UI` | | the same command with the fix | `c2ffeaa7` | 4 passed | | `StudioDesignSurface.packageLessFlows-11553.test.tsx`, whole file, under the verify lock | `85939f9c` | Test Files 1 passed (1); Tests 36 passed (36); lock VERDICT command-exit 0 | | `type-check` of `@object-ui/app-shell` (covers the test file) | `85939f9c` | executed, not from cache; lock VERDICT command-exit 0 | | `pnpm --dir ui exec vitest run scripts/` under the lock | `85939f9c` | Test Files 172 passed, 2 skipped (174); Tests 5,159 passed, 2 skipped (5,161); lock VERDICT command-exit 0 | | `eslint` on the spec and on the test file | `85939f9c` | 0 errors | Two ablations of the new case at `85939f9c`, through `scripts/ablation-replace.mjs`, each restored and proven (blob equals HEAD, `git diff HEAD` empty); the case's two entries go red in both: - **Writable.** In `ResourceEditPage.tsx`, `const hostReadOnly = !!areaHost?.readOnly;` replaced by `const hostReadOnly = !!areaHost;` (anchor 1 → 0, blob `fdd7af7db791` → `cc814ee1e002`): 2 failed, `Unable to find an element by: [data-testid="resource-save"]`. - **No package on the save.** In the same file the save's options were given `packageId: 'com.example.ablation'` (anchor 1 → 0, blob `fdd7af7db791` → `931a9d527629`): 2 failed, `expected { force: false, …(2) } to not have property "packageId"`. Gates run again, each recorded with its exit code. At `90713851`, the 29 that read the ADR text or test sources, all exit 0: `check-adr-0087-registration`, `check-adr-links`, `check:adr-anchors`, `check:adr-index`, `check:adr-symbol-anchors`, `check:closed-ceremony-text`, `check:doc-authoring`, `check:pm-prior-rulings`, `check:pm-governed-merges`, `check:platform-checklist`, `check:nul-bytes`, `check-comment-mask-corpus`, `check:test-source-alias`, `check:cross-package-test-inputs`, `check:undeclared-dep-imports`, `check:skill-identifier-liveness`, `check:pm-governed-prose`, `docs-audit/check-affected-docs`, `check-changeset-no-major`, `check-empty-changeset`, and from `ui`: `check:control-bytes`, `check:test-path-roots`, `check:shell-escape-residue`, `check:vi-mock-specifiers`, `check:vi-mock-inherit`, `check:vi-mock-override-shape`, `docs:check-links`, `check:doc-fences`, `check:doc-types`. At `85939f9c`, which changes the test file alone, the 12 of them that read test sources again: all exit 0. The other derived gates read nothing these commits change, so their run at `5fcf89b5` stands; they were not run again. </details> <details><summary>Dogfood battery</summary> Full battery at the landing head `85939f9c` (os-dev report 7258471243), `pnpm --filter @objectstack/dogfood test` under the verify lock (no shard, no path), after the workspace build at the same head (123 tasks successful, 121 of them restored from turbo's local cache): lock VERDICT command-exit 0 (held 1,888 s); Test Files 495 passed, 3 skipped (498); Tests 4,187 passed, 68 skipped (4,255); no failure. The same battery before the rework, at `5fcf89b5` (os-dev report 7256902761): lock VERDICT command-exit 0 (held 1,828 s), the same counts. The three rework commits change a Playwright spec, one vitest file and ADR text, and no product code. </details> ## Owed before landing - The maintainer's approval (Tier H: `docs/adr/**`, the narrowing, the card total). - The same version as PR-B1: this PR merges before the open Version Packages PR, objectstack-ai#38192. - The two cards named at the top, finished by the seat at landing. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01QsR2jUba5JFq1ejCZ7Gxpk <!-- signed: repo:objectstack#1 · zhuangjianguo · session_01QsR2jUba5JFq1ejCZ7Gxpk --> --------- Co-authored-by: Claude <noreply@anthropic.com>
… notes across three records) (objectstack-ai#38809) <!-- claude-projects-attribution: {"github_login":"os-support-ai"} --> _Requested by **Yibo Wang** · [project thread](https://claude.ai/code/project/chan_01BVUyyPie8gHwoPM18iABwB?thread=cmsg_01BVUyyPie8gHwoPM18iABwBHuLciv5hYVYUu4pypDP48J)_ Fixes objectstack-ai#38438 Clause-②: no Metadata-protocol: none This pull request carries the card's last four rows. The first seven landed with the first pull request of this card, objectstack-ai#38774, merged 2026-11-30. ## 维护者速读 - 用户能看到什么变化:用户无感;只在三份设计记录里补了四条带日期的说明,写明主线现在实际怎么做,原有的决定文字一个字没动。 - 为什么做:属于「每周设计记录修订」滚动清单(11 月 29 日这一周);上一张合并请求已带走七行,这次补齐剩下四行,这份清单就此收口。 - 出错会怎样:最坏是某条说明写得不准,照着设计记录干活的人会被带偏;纯文档、只增不删,可以直接撤回,不影响任何功能。 - 要你做什么:请审这四条说明并批准一次(设计记录须由你本人批)。 ## What changes Three ADR files gain four notes dated 2026-12-01. Every diff line is an addition: 43 lines added, 0 removed. No original decision text is rewritten, and no decision changes. Each note follows the note convention its own record already uses, and each says that the passage it is read with is left as written. Each row's "what is true now" was read against the code on `main` before its note was written. All four rows hold. Where a row's wording did not match the tree, the note says what `main` does; the last column says so and the list under the table gives the detail. | ADR · section | Was (the record's words) | Now (what the note records) | Source PR | Row on the card · result | |:---|:---|:---|:---|:---| | ADR-0161 · Consequences, the bullet "A stored fingerprint and recipe hash are the only index state the service relies on" | "The service keeps none of its own" | The service keeps a sync state for each source: its last build, and the record syncs that failed and are not yet repaired. Where the knowledge plugin can keep it, it is one durable record per source; otherwise the last build is kept in the process and failed syncs are not counted. Whether an index is due for a build is still read from the stored fingerprint and recipe hash, so the bullet's first sentence stands for that decision. The K8 note of 2026-11-28 already names this state | objectstack-ai#38307 | Card body row · **written, corrected to the tree** (the in-process case) | | ADR-0161 · K7, the components table, row "Split algorithm version" | "a constant the splitter exports; it changes when the splitter gives different passages for the same text and settings" | The version is kept per split strategy, and the fingerprint reads the entry for the strategy the source resolves to. A change to one strategy's passages starts a new generation only for the sources that resolve to it. The single exported constant is retired, with no alias | objectstack-ai#38375, objectstack-ai#38452 | Card body row · **written, corrected to the tree** (no version value is written) | | ADR-0085 · the note of 2026-11-27, and the note of 2026-11-30 under it | "Neither key is in the spec yet", and in the later note "The second half stands: `fieldTabs` is not in the spec" | `fieldTabs` is in the spec, an optional list of `{ key, groups }` entries on `ObjectSchema`, so both keys are built. The parse refuses a group the object does not declare, a group two tabs name, a group that places a related list, and a repeated `key`. The tabs are drawn on every tier of the standard record page: the full page, the side preview and a phone. Only the standard record page reads the key, and an object extension does not carry it | objectstack-ai#38742 | 7282251133 · **written** | | ADR-0084 · the table "What the amendment replaces", row "Entries that are not a type", and three sentences that count four entries | "The organization's own flows retire when the door that moves loose items ships."; "The menu also holds four entries that open no type's list"; "Of the four entries that are not a type, the cross-package directory is to leave the menu"; "The four entries that are not a type are 高级 on a package" | The door has shipped and the flows have retired, the entry and the package-less scope it opened alike. Four changes carried it, each named with what it did. The three sentences count the rows of the table under "Entries that are not a type" as it was first written. The note names the entries of a package's menu that open no type's list today: 概览 Overview, the default sharing overview, Diagnostics and 全部类型 All types | objectstack-ai#38185, objectstack-ai#38389, objectstack-ai#38545, objectstack-ai#38598 | 7283216315 · **written, corrected to the tree** (names and no count; a third sentence; the change that built the door) | Every prerequisite of the four rows is merged on `main`: objectstack-ai#38307, objectstack-ai#38375, objectstack-ai#38452, objectstack-ai#38742, objectstack-ai#38185, objectstack-ai#38389, objectstack-ai#38545 and objectstack-ai#38598, and objectstack-ai#38679 and objectstack-ai#38401, which two of the notes point back to. The newest comment on the card when this was opened is the claim amendment, 7296007044; a row added after it is not in this pull request. ### Where a note differs from its row - **ADR-0161, Consequences.** The row says the service keeps a sync state per source. On the tree that state is a durable record only where the knowledge plugin can keep it, with its object registered and a data engine bound. Otherwise the last build is kept in the process and failed syncs are not counted. The note says both. It also says what the row asks for: the stored fingerprint and recipe hash are still what a build is decided from, at boot and on reload alike. - **ADR-0161, K7.** The row says no fingerprint value moves. That is true of the change that brought the table in, and the note says so in those terms. It is not true of every entry since: one strategy's entry has been raised on `main` for a change to its own passages. So the note writes no version value, and says that an entry raised since was raised for its own strategy. - **ADR-0161, the header.** This record lists every dated note in its header, one "Amended" line each. The two notes add two such lines, the seventh and the eighth. That is the record's own convention and it is why the file gains 17 lines for two notes. - **ADR-0085.** The first pull request of this card wrote a note dated 2026-11-30 that says "The second half stands". That sentence was true for one day. The new note is placed under it and names both sentences it is read with; neither older note is edited. It does not repeat what the 2026-11-30 note says of `pinOverview`. The three tiers are read from the code: the list of field tabs is built with no regard to the tier. No test names the three tiers one by one. - **ADR-0084.** The row asks for the entry count as it now stands. The note names the entries and writes no number, since a count in a record goes stale with the next entry. The row names two sentences that count four entries with no note beside them: the one that opens "Entries that are not a type", and "Of the four entries that are not a type, the cross-package directory is to leave the menu", in the note of 2026-11-26 under "The two tiers". The note reads both. It also reads a third, which the row does not name and which has no note either: "The four entries that are not a type are 高级 on a package", under the same heading, quoted as it renders (the record links part of it). So the note says three. As first pushed, the note said two and left out the sentence the row asks about; the contract review found it, and `128528c5` corrects the note. The row names three pull requests. The note names four and says which did which part: the door itself was built by objectstack-ai#38185. The note stays in step with the two ADR-0084 notes of the first pull request, which it does not touch. ## Tests Docs only. No package source is touched, so no package test and no type check is owed for the change. No tested behaviour changed, so there is no ablation. Checked on the committed text: - Each phrase a note quotes from its ADR is in that file as it stands on `main`. A script compared them. One quotation, in the ADR-0084 note, reads as the sentence renders. - Each path a note cites exists on the tree, and each of the seven symbols a note anchors is a declaration in the file named. `pnpm check:adr-symbol-anchors` judges the same and is green. - A probe on the spec source: `ObjectSchema` accepts `fieldTabs` with a declared group. It refuses a group the object does not declare, a group two tabs name, and a repeated `key`. `ObjectExtensionSchema` refuses `fieldTabs` as an unrecognised key, with its guidance. - `ui/packages/app-shell/src/views/studio-design/studioMenuPlacement.test.ts` reads ADR-0084's type table from disk. It was run under the verify lock on the final commit `128528c5`: `Test Files 1 passed (1)`, `Tests 21 passed (21)`. It read the same on `808e249f`, the first commit of the notes. The local gate set is the `dispatch-gates --commands` derivation for this change set, 21 commands, run on the final commit `128528c5`. Each exit code was captured before any pipe. Reconciliation: `Run reconciliation — 21 derived, 21 run, 0 NOT-MEASURED, 0 UNRUN`. The same 21 were derived and run on `808e249f` and on `f7bae5cfb`, with the same result. On `128528c5` the derivation warns that the branch is one commit behind `main` and that one file it derives from changed there. The branch does not merge `main` again while this pull request is open and mergeable, so the list was derived a second time on a throwaway tree of `main` (`d97aaaea9a`) plus this branch: the same 21 commands, and no warning. <details><summary>ADR gates on 128528c (all exit 0)</summary> | Command | Exit | Verdict line | |:---|:---|:---| | `pnpm check:adr-symbol-anchors` | 0 | `check-adr-symbol-anchors: 4606 anchors across 165 records resolve — 1726 symbol (1697 declaration, 29 literal)`, 0 line anchors survive. Seven of the symbol anchors are new with this change. | | `node scripts/check-adr-links.mjs` | 0 | `check-adr-links: 1284 relative link destination(s) under docs/adr/ resolve` | | `node scripts/check-adr-links.mjs --self-test` | 0 | | | `pnpm check:adr-anchors` | 0 | `check-adr-anchors: OK (135 anchored file(s), every governing ADR still referenced` | | `pnpm check:adr-index` | 0 | `adr-index --report: OK — docs/adr/README.md is current, every record parsed` | | `pnpm check:doc-authoring` | 0 | | | `pnpm check:nul-bytes` | 0 | `check-nul-bytes: OK (scanned 29077 text file(s)`, no raw control bytes | | `pnpm check:closed-ceremony-text` | 0 | | | `pnpm check:pm-governed-merges` | 0 | | | `pnpm --filter @objectstack/lint run check:doc-formula-expressions` | 0 | run after building the build closure of `@objectstack/lint` under the verify lock | </details> <details><summary>The other derived families on 128528c (all exit 0)</summary> `node scripts/check-closing-keyword-parity.mjs` and its `--self-test`, `node scripts/check-comment-mask-corpus.mjs` (`24511 files, 0 disagree, 0 unparseable`), `node scripts/ci/plan-test-core-shards.mjs --self-test`, `pnpm check:ci-filter-parity`, `pnpm check:cross-package-test-inputs`, `pnpm check:driver-memory-census`, `pnpm check:gitlink-declared`, `pnpm check:pm-prior-rulings`, `pnpm check:refd-timer-probe`, `pnpm check:watch-hint-literal`. Before the last push: `node scripts/check-commit-card-trailers.mjs --range origin/main..HEAD` exit 0, three commit messages, no card relation and no model identifier in the trailer pair. </details> <details><summary>The overlap check answers exit 1 against one open pull request, objectstack-ai#38812; the reading is below</summary> `node scripts/pm/overlap-check.mjs` on `128528c5`: - Against `main` (`d97aaaea9a`): `origin/main: merges cleanly`. - Against the open pull request objectstack-ai#38812 (a draft opened after this one, head `f3cd7dba76`, one file, 17 lines added to ADR-0161): `VERDICT overlap exit 1`, with the conflict named in the ADR-0161 file. No other open pull request shares a file with this branch. What the conflict is made of, measured on the two heads: - Both add to the header list of dated notes in ADR-0161, at the same place, under its sixth line. This branch adds two lines, "a seventh dated note" and "an eighth dated note". objectstack-ai#38812 adds one line, and it also says "a seventh dated note". - That is the only conflict hunk. The notes themselves sit apart and merge: this branch's under K7 and under Consequences, the other's under K8 with a cross-reference at K1. So this overlap is real, and it is more than text: the two pull requests number their notes from the same count. Whichever lands second has to merge `main`, keep all three header lines, and renumber its own. See the acceptance notes. An earlier reading, on `f7bae5cfb`, answered 1 against the approvals trunk, objectstack-ai#38497. That pull request has since ended without a merge (2026-12-01T01:02Z), and the check no longer lists it. </details> Not run locally: the repository test project behind `test:repo`, and every package suite. CI runs them on the pull request and on the merge group. Every other family CI runs is read from this pull request's check runs, not re-run here. ## Acceptance notes - **Changeset.** None, and the pull request carries `skip-changeset`. `docs/adr/**` ships in no package. - **Governed surface.** `docs/adr/**` lands on the maintainer's approval. This pull request stays a draft; the seat arranges the review at the tier this surface owes and hands it over. - **Why this one ends the card.** The card says it ends when its pull request merges. Seven rows landed with the first pull request and these four are the rest, so every row is carried. The card is open and is not waiting on a decision. - **Claim binding.** The claim amendment, 7296007044, names this branch on a line spelled `Branch (round 2):`, which the guard "The card this PR closes must claim this branch" does not read. The seat restated the claim in the shape the guard reads (comment 7296908473 on the card), and the guard is green on this pull request. - **Landing order against objectstack-ai#38812.** Both pull requests add header lines to ADR-0161 at the same place, and both call their note the seventh; the overlap check answers 1 for that file. Whichever lands second merges `main`, keeps all three header lines and renumbers its own. If this one lands second, its two lines become the eighth and the ninth. If objectstack-ai#38812 lands second, its line becomes the ninth. The seats set the order: this pull request first, by claim stamp (seat 2's `Notify: serial · objectstack-ai#38676 behind objectstack-ai#38438`, mailbox objectstack-ai#38766 comment 7297489558); objectstack-ai#38812 renumbers its line after this lands. - **Seen and left alone.** Outside the four rows, and not changed here. - ADR-0084's table "What the amendment replaces" has a row on the cross-package directory that says "In force until it moves". The amendment of 2026-11-26 moved that entry to Setup, and the menu model on this tree has no entry kind for it. A candidate row for the next weekly card. - The items the first pull request of this card listed under this heading stand as listed there. ## Verification ### Read first 1. `docs/adr/0161-knowledge-platform-boundary-platform-owns-assembly-sync-split-record-return-knowledge-source-is-a-governed-type.md`, the note of 2026-12-01 under the list of Consequences. The highest-risk hunk: it says a sentence of the record no longer describes `main`, and it draws the line between the state a build is decided from and the state that only reports. Check the sentence pair "Where the knowledge plugin can keep it" and "Otherwise", and the bullet "What decides a build is unchanged". 2. `docs/adr/0084-application-builder-information-architecture.md`, the amendment of 2026-12-01 under the table "What the amendment replaces". It says which of four pull requests did which part, it names the three sentences that count four entries, and it names a package's menu entries where the record counts them. Check the four attributions, the three quoted sentences and the four names. 3. `docs/adr/0085-object-semantic-roles-over-surface-hint-blocks.md`, the note of 2026-12-01. It answers a sentence that the note of the day before wrote, and its claim of three tiers is read from code with no test that names them. Check the tier sentence and the list of what the parse refuses. ### Two-minute check Run `git diff --numstat origin/main...HEAD` on this branch. Expect three rows under `docs/adr/`, each with `0` in the removed column, and 43 added lines in total (2, 24 and 17). Then run `pnpm check:adr-symbol-anchors` and expect exit 0 with a line that contains `anchors across 165 records resolve`. --- _Generated by [Claude Code](https://claude.ai/code/session_01WGufzhPdWmTd47Fi2bKYZS)_ <!-- signed: repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS --> --------- Co-authored-by: Claude <noreply@anthropic.com>
repo:objectstack#3 · os-tesla · session_01L9qibyHmxFV4bTFZ5BKnUz
Requested by Tesla · project thread
Part of #38150. This is PR-A2, the console's half of the move door, by the seat's claim (comment 7234216673) and its branch ruling of 16:02Z: PR-A1 (#38185, the server door) is merged, and #38149 (#38204, the package ask this PR reuses) merged at 16:01Z. PR-B1 (the retirement of
adopt-orphansand its two console entries, parked as #38364 at head1852bb898) lands after this PR, so no prerelease ships a console with no way to move loose items. PR-B2 (Studio~org, the redirects to?source=loose, the Q-f E classifier #38061, the ADR marks) follows.Clause-②: yes (widening)
Metadata-protocol: none
Skills-docs: none — no skill under
skills/**or.claude/skills/**teaches the console's lists or loose items; theobjectstack-platformpassage on package-less Setup rows is about overlays of shipped items, which are not loose (searched at this head)Size: 1,380 lines (additions + deletions, generated files included: 1,369 added, 11 deleted, 15 files;
git diff --numstat eef1cbfe4 be8e0d5dc, base maineef1cbfe4). With A1's 1,947 and B1's 3,123 the card is past 3,000 (#38280's per-card line), so this PR is Tier H.维护者速读
/studio/~all/metadata/<类型>)里,来源下拉多了「散落项」。选它后,有编辑权限的人可以逐行勾选或全选,点「移入软件包…」,选好软件包后先看一次试运行:每一项移入后地址怎么变,或者为什么被拒。确认后整批移入。设置的「软件包」页上会提示「有 N 个散落项,不属于任何软件包」,按类型列出,点进去就是那种类型的散落项列表。What changes
The "Loose" source value (
metadataListState.ts,ResourceListPage.tsx,useListOrderedNames.ts).?source=loosejoins the list's address state. On the cross-package leg (allLeg: an area host with no package, outside the environment scope) the list offers it, as "Loose (N)" in both the Studio and the Setup toolbars.isPackageLessItemon its served_packageId(absent,'', or thesys_metadatasentinel), the card's "neverclassifyProvenance": that classifier also files a.custompair item and a served overlay as runtime, so "Modified and new" holds them and "Loose" does not.loosemember. Absent, as on a package's own leg,source=loosereads as every source, the way an unoffered filter does. The detail's ‹ › order reads the same member, so prev and next agree with the list.Select and move (
ResourceListPage.tsx,looseMove.ts,LooseMoveDialog.tsx).useCanAuthorMetadata, and not walled) gets a select column first in the table and a selection bar above it: "Select all (N)" over the rows the filter shows, the count selected, and "Move into package…". A reader who may not author sees the loose rows with no select box and no bar.PackageCreateAsktakes an optionaltitleanddescription; the create's are unchanged). "New package…" in the ask works as it does for a create.POST /api/v1/packages/:id/move-inwithdryRun: true) and draws its answer:would_move: each item,(draft only)where only a draft moves, the address change (_env/NAME→NAMESPACE/NAME) and the AI face name change where the door reports them. Two notes follow. The first is the dry-run caveat: some save checks run only on the real move, and if one refuses, nothing moves. The second is L2's N4 (record 7236830081): reverting the move's package commit takes the items out of the package and does not make them loose again.refused: each refused item with the door's own code and sentence. ForREFERENCE_LEFT_BEHIND, "Add the loose items they use and check again" adds thereferencesto the selection, which may be of other types, and asks the dry run again.movedcloses the dialog, says "Moved into PACKAGE: N." and re-reads the list.moveLooseItemsresolves it as the door's answer (error.detailswithoutcome: 'refused'), and every other failure throws with the server's sentence, which the dialog draws with Try again.The Packages page banner (
LooseItemsBanner.tsx,PackagesPage.tsx)./studio/~all/metadata/TYPE?source=loose. That is the acceptance's "from the Setup → Packages banner, a person reaches a flow's Loose list in the UI, with no typed address".GET /meta/:typeper type that takes a runtime write (allowRuntimeCreateorallowEnvironmentOverlay; a type that takes none holds no loose item), with the type's own hide hook applied, the same rows its list counts. On the showcase boot that is 30 of the 40 served types, and the 30 reads in parallel took 366 ms. A type whose read fails is named as not counted, never folded into a smaller total.i18n. 31 keys in
@object-ui/i18n's studio namespace, en and zh:engine.list.sourceFilter.loose,engine.looseMove.*,engine.looseItems.*. No other locale carries the studio namespace.Changeset.
38150-move-loose-items-console.md:@object-ui/app-shelland@object-ui/i18npatch,Clause-②: yes (widening),Metadata-protocol: none, as #38204 declared for the same kind of console widening.Tests
New, each with its control:
ResourceListPage.looseMove-38150.test.tsx(7)?source=looseon~alllists exactly the package-less rows (none,'',sys_metadata), never a.custompair item or an overlay; with no filter every row is listed. The select column and bar appear for an author, not for a reader who may not author. Select all → the ask opens with nothing picked and the move's question → the dry run carries the three items,dryRun: true→ the confirm names the package by its name and shows the address change → Move resends the same items withoutdryRun. One row selected moves that row alone. A package's own leg ignores?source=looseand draws no selection.LooseMoveDialog-38150.test.tsx(5)REFERENCE_LEFT_BEHINDoffers to add the dataset, the next check carries it, and Move moves both. A refusal with noreferencesoffers nothing to add. A refusal on the real move reads as nothing moved, andonMovedis not called. A failure that is not an answer shows its sentence and Try again.looseMove-38150.test.ts(8)source=loosecodec round-trips, and an unknown value reads as all.loosekeeps package-less rows whereruntimealso keeps the.customrow. With noloosemember every row is kept. The 422 resolves as the answer; a 403 throws the server's sentence; the body carriesdryRunonly on a dry run. References are added once each.LooseItemsBanner-38150.test.tsx(5)/studio/~all/metadata/flow?source=loose). A type with no runtime write, andpackage, are not read. A failed read is named. Nothing is drawn or read for a non-author, and nothing is drawn at zero.Ablation. With the list's
loosereader set torow.source === 'runtime'(the classifier the card forbids), two cases ofResourceListPage.looseMove-38150go red: the exact-rows case and the select-all move (its dry run then carried the pair item and the overlay). Restored, 7 of 7 pass.Verification
Local, on this branch, after a declaration build of
./packages/**and@object-ui/app-shell's dependencies:@object-ui/app-shelland@object-ui/i18n(pnpm --dir ui exec vitest run packages/app-shell packages/i18n), before the merge of main: 2,570 files, 2,569 passed and 1 skipped; 25,917 tests passed and 22 skipped. After the two display fixes, the touched files (everyResourceListPage*, the four new files,PackageCreateAsk*, all ofpackages/i18n) passed: 132 files, 2,048 tests passed and 13 skipped. After the merge of main and the collection imports, the four new files pass 25 of 25.@object-ui/app-shelltype-check(tsc --noEmitandtsc -p tsconfig.test.json) passes after the merge of main. The first run failed onlooseMove-38150.test.ts's untypedvi.fntuple, and that was fixed.node scripts/pm/dispatch-gates.mjs --commandsderives 39 families for this tree, the same 39 before and after the merge of main. 38 passed on the first run.check:test-source-aliasfailed on three of the new test files, which reachedcelAuthoring's dynamic@objectstack/lintimport throughpackageActions.tsx. Each now has the module-top import, and the gate passes. After the merge, the four gates that read the diff againstorigin/main(check-adr-0087-registration,check-changeset-no-major,check-empty-changeset,check:test-source-alias) andcheck:undeclared-dep-importsandcheck:type-check-coveragewere run again and pass.dispatch-gates --ran: 39 derived, 39 run, 0 NOT-MEASURED.overlap-check.mjsbefore the first push:origin/mainconflicted inResourceListPage.tsx(the lucide import, beside feat(plugin-grid,app-shell): save the import wizard's column mapping as a shared mapping, and Manage it in Studio #38357'sX) andmetadataListState.ts(beside feat(plugin-grid,app-shell): save the import wizard's column mapping as a shared mapping, and Manage it in Studio #38357'stargetObjectfilter). Both are resolved in the merge, keeping both sides. feat(studio): App Studio's package overview gets Export as a button, a Publish history tab with the revert, and is where opening a package lands #38318 shares the two i18n files and merges cleanly.Walkthrough (a real stack)
At
c27f9ab24(the two display fixes in; the merge of main after it touches neither surface),pnpm console:build, then the showcase booted withobjectstack dev --ui --seed-adminon a fresh database. Through the API: an installed writable packagecom.probe.zeta(name Zeta, namespacezeta), two loose flows (probe_loose_flow,probe_loose_flow2) and a loose objectprobe_widget, each saved with no package. Then, in the browser (Playwright, 1400×900):?face=admin) draws "4 items belong to no package" with Flow (2), Object (1), Datasource (1). The datasource is the showcase's own loose row./_console/studio/~all/metadata/flow?source=loose: two rows, the select column, "Select all (2)"._env/probe_loose_flow→zeta/probe_loose_flow, the caveat and the undo note._packageId: com.probe.zeta,GET /meta/flow/zeta/probe_loose_flowanswers 200 andGET /meta/flow/_env/probe_loose_flow409, with no restart.probe_widgetinto Zeta: refusedNAMESPACE_PREFIX, "Object 'probe_widget' is missing the package namespace prefix. Rename it to 'zeta_probe_widget' (namespace = 'zeta').", Move disabled.Screenshots, at device scale 2: in the project files under
card-38150/a2-walkthrough/,1-packages-banner.png…7-banner-after.png.Owed before landing
1852bb898's commits.🤖 Generated with Claude Code
https://claude.ai/code/session_01L9qibyHmxFV4bTFZ5BKnUz