Skip to content

fix(metadata-protocol): FORM_ADDRESS_TAKEN carries the holding form as details.holder; Setup reads it - #38712

Merged
objectstack-fleet[bot] merged 4 commits into
mainfrom
claude/issue-38626-form-address-holder-details
Nov 30, 2026
Merged

objectstack-fleet[bot] merged 4 commits into
mainfrom
claude/issue-38626-form-address-holder-details

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

Requested by Steve · project thread
Fixes #38626
Clause-②: yes (widening)
Metadata-protocol: none

维护者速读

  • 管理员在设置的公开表单页打开一个表单、却因地址已被另一个表单占用而被拒时,提示里点名的占用表单改由服务器的拒绝直接给出;之前页面自己重算,列表过期时可能点错名或不点名。
  • 属于公开表单(表单独立类型)那条工作线,替设置页去掉一份与服务器重复的占用规则。
  • 出错时最坏是提示里说"另一个表单占用了地址"但不点名,保存本身仍被拒、不会写入;可直接撤回本 PR。
  • 无

What changes

  • @objectstack/metadata-protocol: formAddressClashRefusal sets holder: { name, packageId } on the 409 FORM_ADDRESS_TAKEN it throws (packageId is null for a form bound to no package). The message is unchanged.
  • @objectstack/types: one recogniser, formAddressRefusalHolder(error) (code FORM_ADDRESS_TAKEN, declared 409, a well-shaped holder), read by resolveThrownHttpError into details.holder. That is the dispatcher door's answer (and every door that answers from the resolver).
  • @objectstack/rest: the declared-4xx arm of resolveErrorResponse (the door RestServer's PUT /meta/:type/:name answers through) adds details.holder next to the existing details.candidates member, through the same recogniser. Measured before writing: neither door forwards a thrown .details (the resolver's list is closed on purpose), so the details thrown in protocol-package-commits.ts were no path to reuse.
  • Setup (ui/packages/app-shell): refusedAddressHolderOf(err, rows) reads the holder off the refusal in both door spellings (body.details.holder flat, body.error.details.holder nested). The page no longer re-reads the form list, and heldSlug and publicAddressHolderOf (the local copy of the server's rule) are deleted. The user-facing wording from fix(app-shell): Studio form follow-ups: form menu icon, clash messages name forms by title (#38621) #38678 is kept: the holder is named by its shown title, plus its package display name when the titles match. Only the data source changed. The title comes from the list the page shows, matched by name and package (stable, unlike the slug). A holder the list does not show (a form that is not anonymous) is named by its name without the object prefix.
  • Clause-②: yes (widening) (after L1-a REWORK 7271615422): @objectstack/types gains two exports from its . entry, formAddressRefusalHolder and FormAddressRefusalHolder, and both doors' 409 FORM_ADDRESS_TAKEN bodies gain details.holder, inside the error envelope's declared open slot (details), the same shape as the details.candidates precedent. Nothing is narrowed; the level stays patch.

Tests

  • packages/rest/src/public-form-two-type-withdrawal.test.ts (a new top-level describe in the shared harness): a real protocol on SQLite. RestServer's registered PUT /api/v1/meta/:type/:name answers 409 with code: FORM_ADDRESS_TAKEN and details.holder. The same refusal thrown by the real saveMetaItem, passed through thrownAnswerOf (the dispatcher's resolver), answers the same status, code and details.holder.
  • packages/types/src/thrown-http-error.test.ts: the holder is carried, a package-less holder included, and both status spellings are read. CONTROL: another code, another status, or a malformed holder carries nothing.
  • ui/.../setup/publicForms.test.ts and PublicFormsSetupPage.test.tsx: both door spellings are read. A stale-list case: the list was read while form A sat at the address, then A moved and form B took it. The refusal names B and the page says B, never A. No form-list read follows the refusal. With no holder, or a malformed one, the page says another form holds the address and names none.
  • Ablations (each mutated on disk, run red, restored with git checkout HEAD): dropping the REST member reds the PUT pin (details.holder undefined). Dropping the resolver member reds the types case. Dropping the flat-body read reds 5 UI cases, the stale-list case included.

Acceptance notes

  • Measured: the details objects thrown in packages/metadata-protocol/src/protocol-package-commits.ts (targetPackageId, owners, collisions) are dropped by both HTTP doors. This was found by reading the code, with no reproduction through a public door, so it is noted here and not filed.
  • A holder the page does not list is now named by its name without the object prefix, where the old list re-read used its label. That form is never a public form, so the page never showed its title.
  • Changed lines are about 390 without the changeset, over the dispatch's estimate of about 200: 159 are deletions (the re-derivation and its tests), and the rest are both-door tests and docblocks.

Verification

Read first, by risk:

  1. packages/rest/src/error-response.ts declaredDetailsMember: it now runs on every route's declared-4xx answer, gated on the recogniser.
  2. packages/types/src/thrown-http-error.ts formAddressRefusalHolder: the shape gate.
  3. ui/packages/app-shell/src/views/setup/publicForms.ts refusedAddressHolderOf: the two spellings.

Two-minute check: pnpm --filter @objectstack/rest exec vitest run --maxWorkers=2 src/public-form-two-type-withdrawal.test.ts -t 38626 should show 1 passed.

Local readings (head d57aac6)
  • types thrown-http-error.test.ts: 27/27 passed. rest public-form-two-type-withdrawal.test.ts: 64/64 passed.
  • ui publicForms.test.ts, PublicFormsSetupPage.test.tsx, publicFormDesign.test.ts: 3 files, 82/82 passed.
  • typecheck for types, metadata-protocol and rest: exit 0. UI type-check: NOT MEASURED, because the ui closure was not built locally; left to Type Check UI.
  • dispatch-gates --ran: 76 derived, 74 exit 0, 2 NOT MEASURED, both exit 3 PREREQUISITE NOT MET (check-plugin-teardown-shape --self-test needs an unshallow clone, check:dual-build-cjs-loads needs a full build). CI runs both.
  • check-platform-checklist --changed-from origin/main: 0 anchored files.

Generated by Claude Code

🤖 Generated with Claude Code

https://claude.ai/code/session_01ADHkmQu29PQequUrXXHYMn

…s details.holder; Setup reads it

Claude-Session: https://claude.ai/code/session_01ADHkmQu29PQequUrXXHYMn
Co-authored-by: Claude <noreply@anthropic.com>
@github-actions github-actions Bot added size/m documentation Improvements or additions to documentation tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface labels Nov 30, 2026
@github-actions

github-actions Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

This PR changes 3 package(s): @objectstack/metadata-protocol, @objectstack/rest, @objectstack/types, touching 17 documentable anchor(s).

19 hand-written doc(s) name something this change touched — list omitted above 15 rows. Re-derive on the tree named below: node scripts/docs-audit/affected-docs.mjs --json d2caaec40d73a6e8a5bc88554518f5333715ef63.

⛔ 10 release-owned page(s) also affected — read-only, see AGENTS.md Documentation Guardrails.

What this run could not see
  • the SDK route bridge reached 69 of 252 client-bound route-ledger rows — the other 183 have no registrar path: tail to select them, so pages documenting THEIR client methods cannot appear above, on this or any run. Of those 183: 0 are remediable by widening that discovery convention (an in-repo file declares the path; the convention did not scan it); 59 are structural — on a ledger where NOT ONE row is declared in-repo, so no discovery change reaches them at any price; 124 are undecided (no in-repo declaration, on a ledger that has other in-repo registrars — absence and an unreadable spelling are not distinguishable here). The rows themselves: node scripts/docs-audit/affected-docs.mjs --bridge-coverage
  • a page that states a rule by its inputs shares no identifier with the emitter that implements the rule, so an emitter-only diff cannot list it — not on this run and not on any run. Measured on fix(driver-sql): emit varchar(maxLength) for a text field a declared index keys on #11430: content/docs/protocol/objectql/types.mdx documents the text-family column mapping by the ObjectQL type names it maps FROM (text / textarea / html) while the diff changed createColumn; it went unlisted, and it was the page that diff falsified, in four places. No shared token exists to detect this on, so a rule your change carries has to be re-read by hand in the pages that restate it.
  • a key NAME is not a key, so the hand re-read the line above prescribes can land on the wrong schema. The same spelling is authorable on one governed type and a [REMOVED] tombstone on another for each of active, aria, joins, objects, template, tools and version (censused on [finding] tools is a key on BOTH AgentSchema (tombstoned, dead) and SkillSchema (live, cloud-attested), so a name-based search attributes skill examples to the agent key — it produced a false stop-the-line alarm on PR #19059 #19093 over the liveness ledger's governed types, top-level keys); nothing in a search result distinguishes the two, so a grep hit on a LIVE example reads as evidence about the DEAD key. Measured on fix(spec): the agent.tools liveness row says dead — it claimed live on a key the schema tombstoned #19059: content/docs/ai/agents.mdx was reported as contradicting the agent.tools tombstone over its tools: example at :161, which is inside the defineSkill({ block opened at :155 — the page was already correct. Settle ownership by PARSING the value against both schemas, never by the name: that literal PASSES SkillSchema, and as an AgentSchema it FAILS at tools with the tombstone prescription. ⛔ These names are not the whole class — a key retired through a .strict() guidance map leaves no tombstone in the walked shape and none of them here (tool.category, live as AIToolDefinition.category).

Coarse fallback — 34 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): node scripts/docs-audit/affected-docs.mjs --json d2caaec40d73a6e8a5bc88554518f5333715ef63 → packageMentionDocs.

Which tree this was computed on

This run read content/docs from 6150a192ad0dee3e6da032c536de52252be60d84 — the merge of head e19ef2c925757c6833d1738bda5841cf827da881 into base d2caaec40d73a6e8a5bc88554518f5333715ef63, which is what actions/checkout gives a pull_request run. Not the PR head.

A worktree cut from an older main holds a different content/docs, so re-deriving there can legitimately return a different list — that is a different tree, not a wrong row. To answer on the same tree:

# while this PR is open — GitHub drops the merge commit once it closes
git fetch origin 6150a192ad0dee3e6da032c536de52252be60d84 && git checkout 6150a192ad0dee3e6da032c536de52252be60d84
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin d2caaec40d73a6e8a5bc88554518f5333715ef63 e19ef2c925757c6833d1738bda5841cf827da881 && git checkout -B drift-repro d2caaec40d73a6e8a5bc88554518f5333715ef63 && git merge --no-ff e19ef2c925757c6833d1738bda5841cf827da881

node scripts/docs-audit/affected-docs.mjs --json d2caaec40d73a6e8a5bc88554518f5333715ef63

⚠️ That checkout carried uncommitted changes, so the commit above does not fully identify what was read.

Advisory only, and a precision-first one (#9192): a page is listed because it names a
symbol, wire route or SDK method this diff touched — not because it mentions a changed
package. Each row says which anchor put it there, so a wrong row is reportable rather than
merely annoying. To re-verify, run the docs-accuracy-audit workflow scoped to these files:
node scripts/docs-audit/affected-docs.mjs d2caaec40d73a6e8a5bc88554518f5333715ef63 → pass the list as
args.docs, on the commit named under Which tree this was computed on.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmQm8PTU4AkVU5kdwEv
L1-a, the seat's L1 thread · 2026-11-30T07:19Z · first review

席位核对

REWORK @ d57aac6 (card #38626; draft; 10 files, +240/−159)

Must-fix

  1. The declaration should read Clause-②: yes (widening), not Clause-②: no, in both the PR body (line 4) and .changeset/38626-form-address-holder-details.md. This is the zone's question ①. Placing holder in the declared open slot details: z.unknown() keeps the wire schema unmoved, but this PR changes @objectstack/types' published face in two ways:

    • New exports. formAddressRefusalHolder and the interface FormAddressRefusalHolder are exported from the . entry (packages/types/src/index.ts:43, export * from './thrown-http-error.js'). contract-review.md reads the published face by the exports map, and a new export moves it. This is the same reading as fix(types): sendError says Vary: Accept-Language when its body carries a userMessage #38695 (7270364941), where one optional member on the exported EnvelopeResponse was a widening.
    • The wire. Both doors' 409 FORM_ADDRESS_TAKEN bodies gain details.holder, a REST widening. That is the pair ruling A grades yes (widening) + Metadata-protocol: none → patch (check-changeset-no-major.mjs:3740).

    Nothing is narrowed: resolveThrownHttpError's details only gains a member when the shape matches. So the levels stay patch, and only the declaration line moves. Once declared, an L2 at TIER_DEFAULT is owed, which check-owed-reviews will then list.

Everything else passed

  • Producer. formAddressClashRefusal sets holder = { name, packageId | null } beside the unchanged message, and holderPkg feeds both. The recogniser matches by shape: the code, a declared 409 through either status spelling, a non-empty name, and a packageId that is a string or null. It is read by resolveThrownHttpError (dispatcher) and by the REST declared-status arm (declaredDetailsMember), so there is one recogniser and no second copy. declaredDetailsMember merges candidates and holder, and gives nothing when both are absent, as before.
  • Setup. refusedAddressHolderOf reads both envelope spellings off err.body. MetadataError.body is set by metadata-client.ts:983, so the raw body really is there. The display name comes from the page's own rows by (name, packageId), or else from shownName. Removing publicAddressHolderOf and heldSlug deletes the client's second copy of the server's rule. That is the card's point: a stale list can no longer name the wrong form. @object-ui/app-shell is private: true, so dropping that export needs no changeset or declaration.
  • My runs (fresh worktree): packages/types/src/thrown-http-error.test.ts 27/27; the new [#38626] pin in packages/rest/src/public-form-two-type-withdrawal.test.ts 1/1. Ablation: dropping err.holder = … in protocol-form-writes.ts and rebuilding metadata-protocol turns the rest pin red (both doors' expectations hang on it). Restored.

The zone's other questions

  • ② The deviations are accepted. The two-door pin sits in public-form-two-type-withdrawal.test.ts, outside the claimed surface. That is the shared harness for this door (it already boots RestServer with the form fixtures), and that is the reason AGENTS.md gives for using it. The line count over the estimate is not a finding at +240/−159. The local UI type-check was not run, and CI's Type Check UI is the reading of record. It is still running, so landing waits for it.
  • ③ The out-of-scope finding is a finding, not this PR's. The suspicion is that both HTTP doors drop the details that protocol-package-commits.ts throws (targetPackageId, owners, collisions). It goes through the seat's card gate (finding + the triage knock). It is inferred from the code and not reproduced, so the card should say so and carry the reproduction as its first step. It does not block this PR.

Checks at this head (read before writing): 20 success, 10 skipped, 0 failure, 36 in progress (Test Core, Test UI, type checks and lint). Landing waits for them green.
Dogfood: not owed (not a narrowing). L2: owed at TIER_DEFAULT once must-fix 1 lands; the seat routes it.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmT9HTWLMN33WUVxVWB
L1-b, the seat's L1 thread (successor of L1-a) · 2026-11-30T07:23Z · delta review

席位核对

ACCEPT @ e19ef2c (delta from d57aac6, REWORK 7271615422; fast-forward, one commit e19ef2c9)

  • Must-fix 1 is resolved. Clause-②: yes (widening) now reads in the changeset .changeset/38626-form-address-holder-details.md and in the PR body (line 4). Metadata-protocol: none and the three patch levels are unchanged, as ruling A gives for this pair.
  • The delta is the changeset alone: git diff d57aac66..e19ef2c9 touches only that file (+3/−1). The code and tests are byte-identical to the head L1-a ran (types 27/27, the rest pin 1/1, the err.holder ablation red), so those readings carry.
  • The new changeset sentence, read against the head. "@objectstack/types gains two exports, formAddressRefusalHolder and the FormAddressRefusalHolder type": true, thrown-http-error.ts:281 and :301, reached from the . entry through packages/types/src/index.ts:43 (export * from './thrown-http-error.js'). "the 409 FORM_ADDRESS_TAKEN body of both doors gains the details.holder member": true, the REST declared-4xx arm (declaredDetailsMember in packages/rest/src/error-response.ts) and the resolver (thrown-http-error.ts:433), as pinned in the shared harness. The PR body's new Clause-② paragraph says the same and nothing more.
  • The out-of-scope finding (protocol-package-commits.ts thrown details dropped at both doors) stays with the seat's card gate, as L1-a wrote; the body's Acceptance notes record it as unreproduced.

Checks at this head (read before writing, latest per name): 5 success, 7 skipped, 0 failure, 15 in progress (type checks, lint, Check Changeset). The one cancelled run of PR-body guards was superseded by a success of the same name at this head (07:21:56Z). Test Core and Test UI have not reported yet. Landing waits for every check green.
L2: owed at TIER_DEFAULT (face declaration; check-owed-reviews lists it at this head with no record, claim or hand-off). Dogfood: not owed (not a narrowing).

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmQu29PQequUrXXHYMn

Contract-review-claim: session_01ADHkmQu29PQequUrXXHYMn · head e19ef2c · 2026-11-30T07:25Z

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmQu29PQequUrXXHYMn
o3-U zone · 2026-11-30T07:26Z · contract review, face declaration

Contract review

Served-tier: TIER_DEFAULT
Head-sha: e19ef2c925757c6833d1738bda5841cf827da881
Local-runs: none
Scope: packages/types/src/thrown-http-error.ts + packages/rest/src/error-response.ts, packages/metadata-protocol/src/protocol-form-writes.ts, .changeset/38626-form-address-holder-details.md
Security-touching: no
Rule-change-verified: none

① Derived judgments

  • New exports from @objectstack/types' . entry: formAddressRefusalHolder(error) and the FormAddressRefusalHolder interface ({ readonly name: string; readonly packageId: string | null }). Additive; no existing export changes shape.
  • The recogniser matches by shape only: code FORM_ADDRESS_TAKEN, a declared 409 in either status spelling, a holder object with a non-empty string name and a packageId that is a string or null. Anything else gives undefined, so resolveThrownHttpError's details gains a member only on that refusal and is otherwise byte-identical (an empty details stays absent, as before).
  • The producer (formAddressClashRefusal) sets holder from the same holderPkg the message uses, so the data and the sentence cannot name different forms.
  • The RestServer door reads the same recogniser in its declared-status arm (declaredDetailsMember), merged with the existing details.candidates; with neither present it gives nothing, as packageScopedCandidatesMember did. One recogniser, no per-door copy.
  • Wire: both doors' 409 FORM_ADDRESS_TAKEN bodies gain details.holder, inside the error envelope's declared open slot (details: z.unknown().optional()); status, code and message are unchanged. No spec schema moves.

② Semver level

patch on @objectstack/types, @objectstack/metadata-protocol and @objectstack/rest, with Clause-②: yes (widening) and Metadata-protocol: none on both the PR body (line 4) and the changeset, after L1-a REWORK 7271615422 and L1-b delta ACCEPT 7271694740. New exports and a new member on a refusal body accept everything they accepted before. @object-ui/app-shell dropping publicAddressHolderOf is a private: true package and publishes nothing.

③ Boundary flags

Implemented-by: claude/issue-38626-form-address-holder-details
Reviewed-by: session_01ADHkmQu29PQequUrXXHYMn

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmQu29PQequUrXXHYMn
Landing · zone o3-U · 2026-11-30T07:50Z · head e19ef2c925757c6833d1738bda5841cf827da881

  • L1: delta ACCEPT 7271694740 (L1-b) at this head, after REWORK 7271615422 (L1-a).
  • L2: face declaration, TIER_DEFAULT record PASS 7271739402 at this head (check-owed-reviews: DONE).
  • check-governed-merges --pr 38712: NOT governed, 401 changed lines ≤ 3000. landing-k: K = 6.
  • Checks at this head: 61 success, 12 expected skip, 0 failure, 0 pending. The one cancelled PR-body guards run (07:21:21Z) is superseded by a success of the same name at this head (07:21:56Z).
  • Action: pr_ready + automerge_enable. The PR says Fixes #38626.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 30, 2026 07:50
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 30, 2026
Merged via the queue into main with commit 2d6102c Nov 30, 2026
74 of 75 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-38626-form-address-holder-details branch November 30, 2026 08:19
Nenzyz pushed a commit to Nenzyz/objectstack that referenced this pull request Dec 1, 2026
… that name no package give the answer the read names (objectstack-ai#38752)

<!-- claude-projects-attribution: {"github_login":"os-steve"} -->
_Requested by **Steve** · [project
thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9BzWvmsAKskRGFXQ4iwDJDW)_

Fixes objectstack-ai#34452

Refs objectstack-ai#34346, objectstack-ai#34417, objectstack-ai#33904, objectstack-ai#34258 (the fold's members, closed into
objectstack-ai#34452 on 2026-11-20) and objectstack-ai#33127 (heal 2 only)

Clause-②: no (narrowing)
Metadata-protocol: none
Skills-docs: none — no key an author writes changes; the moved answers
are writes, a restart and action reads that name no package, which the
skills already teach as "name the package"

## 维护者速读

-
用户能看到什么变化:同名元数据在不点名包时,写入、重启后的读取、动作的读取,都和读取给出同一个答案:停用包当作不存在,环境自己的条目先答,不再随保存或注册顺序变化。
- 为什么做:这是同名读取折叠组 objectstack-ai#34452 的写门与水合半边(读门半边是已合并的 objectstack-ai#38640),合并即关 objectstack-ai#34452;四张成员卡与
objectstack-ai#33127(只修第二处 heal 2)随折叠组关闭。
- 出错会怎样:不点名包、去写或读共享名字的调用方,会改拿 409 冲突或环境自己的条目;点名包就能拿回原来那份。改动可以整体撤回。
- 要你做什么:无(契约复审由席位送审)。

## What changes

Five criteria, one commit each, on `main` after objectstack-ai#38640:

1. **objectstack-ai#34346** (9d731b0): two enabled packages ship a name, and its
stored rows are bound to a disabled package D and to one of them, E. The
bare publish save, the bare draft save and the bare delete now refuse
409 naming the two enabled holders, as the bare read does. They never
name D, and they write or remove nothing. `?package=E` saves and deletes
as before. Before, the publish save wrote E's row (200), and the draft
save and the delete refused naming E and D.
(packages/metadata-protocol/src/protocol-save.ts,
protocol-diff-delete-load.ts)
2. **objectstack-ai#34417** (0a14e90, criterion rewritten by the seat to ruling
6942962369): the environment's package-less doc row, hydrated after the
artifacts registered (`loadMetaFromDb`), answers first on every bare
door, on both transports and in both registration orders. Each holder's
exact address (the plain read and `/layers`) reads that holder's own
doc. Before, the hydrator grafted the first registered holder's envelope
onto the row, so `?package=FIRST` served the environment's row under
that holder's name and the bare doors refused 409.
(protocol-registry-hydration.ts)
3. **objectstack-ai#33127 heal 2** (a8bf411, `Refs`): for the three healed overlay
types, a package-less row with no holder served wears no envelope and is
recorded with no holder, by the hydrator and by the heal alike. The
enable that later serves one holder builds the row under that holder's
envelope, as the hydrator lays it then. Before, the lookup that names no
package answered a disabled holder's artifact, and the heal dropped the
record. No door's answer moves (registry-only; the pins are in
packages/objectql/src/package-scoped-exact-qualifier.test.ts).
4. **objectstack-ai#33904** (616d76d, b61bcd2, 73c2de8 and 9910fbc, ADR-0150 D4,
ruling 6942962369): a package's action of a name on one object, and the
environment's own package-less action of the name on another object that
no package's action of the name binds, are separate items at D4's key
`(package, objectName, name)`. One predicate,
`holdsEnvironmentOwnAction` (sys-metadata-repository.ts), reads the
environment's own action off the item's active rows. The read naming no
package serves its row and version, the merged list slots an action by
`(name, object)` where a package's action of the name binds that object,
an object-less action being a key of its own (elsewhere, by name as on
`main`, so a platform item and the environment's object-less row of its
name stay one slot, which `/actions/_env/OBJECT/NAME` reads as the
platform item's key: runtime action-package-addressing.test.ts), and the
delete naming no package removes the environment's row and retires the
registry's bare-slot entry it left. With no such row, every door answers
as before. Before, the plain read, `/layers` `effective` and
`/published` served the package's item, the list named only it, and the
delete removed the package's row. The same holds with the package's
action object-less and the environment's on an object (73c2de8; before
it, the list named only the package's).

**List cells with no environment-own action** (73c2de8, declared in the
changeset bullet "The merged action list where a package binds the
object" and in the `environment-action-on-another-object-answers-first`
entry). Two packages P1 on `account` and P2 on `contact`, a package-less
row on `account`: FROM the row listed under both packages and P2's own
action dropped, TO the row listed as P1's customization and P2's own
action listed. A list scoped to a code package on `account`, the
environment's row on `contact` passed as a stand-in: FROM the package's
slot serving the environment's body, TO the package's own action. A
platform action of the name (no package, no stored row) on `lead`, or
object-less, beside a package's action on `account` or object-less
(9910fbc, the contract review's S3): FROM the platform action dropped,
TO both listed (the bound variant moved at 616d76d, the object-less one
at 73c2de8); the bare read already refuses that name 409 naming both,
so the list now names the two candidates the refusal names. Pins:
packages/metadata-protocol/src/protocol.action-list-slot-key.test.ts,
red on `main` (8) and on b61bcd2 (3: the object-less cells).
5. **objectstack-ai#34258** (fa54140, ADR-0150 D3/D4): a package-less action row is
withheld or served by the holders at its own `(object, name)` key, not
the name's. With two or more holders bound to the key, the envelope
lookup (`lookupArtifactItem`, protocol-artifact-lookup.ts) lends the ONE
enabled holder's envelope; with two enabled holders, or none, it answers
as before. The face's withhold judges the key's holders
(`actionKeyHoldersOf`, protocol-meta-item-face.ts). Before, a disabled
and an enabled holder on the row's object made the row wear the disabled
one's envelope when it registered first, and the read withheld it (404).
And an enabled package holding the name on another object kept a key
whose every holder is disabled served.

**Narrowing cell.** Every holder on the row's object disabled (A and B
on `account`), an enabled C holding the name on `contact`, the
environment's row on `account`: the read naming no package moves FROM
200 serving the row (the name's holders were judged, and C is enabled)
TO 404, as a key whose every holder is disabled answers with no other
holder of the name. The `!` and `Clause-②: no (narrowing)` cover it.
Pin: rest `[objectstack-ai#34258]` "A and B disabled on `account`, C enabled on
`contact`" (the "objectstack-ai#34258 key" ablation arm turns it red). The changeset
bullet, the `package-less-action-row-judged-at-its-key` entry and the
pin title give it as FROM 200 → TO 404 (b0e3f1d, text only).

Plus (10c011f) four ADR-0087 semantic entries under step 19:
`bare-write-beside-disabled-row-refused-naming-shippers`,
`hydrated-doc-row-wears-no-holder-envelope`,
`environment-action-on-another-object-answers-first` and
`package-less-action-row-judged-at-its-key`. Also the changeset
`.changeset/34452-same-name-writes-and-hydration.md` (BREAKING banner,
FROM and TO per criterion; objectstack-ai#33127 heal 2 noted as moving no door).

What `Fixes objectstack-ai#34452` leaves open, each with its home:

- objectstack-ai#34452's scope appendix 7259555802 listed an `_env` cell (the `_env`
draft and layered reads answering 409 naming the disabled registry
holder). It is moved out of this PR on the seat's ruling, because it is
a different mechanism: `admitEnvironmentQualifier` falls back to
registry holders, disabled ones included. Filed as objectstack-ai#38753.
- objectstack-ai#33127 heal 1 (see Acceptance notes): filed as objectstack-ai#38754.
- A bare read of a name whose every holder is disabled answers 404: not
to be done, ruled on objectstack-ai#34348 (7187668758).
- With ONE enabled shipper beside a disabled one, the bare draft save
and the bare delete still refuse 409 naming the disabled package: filed
by the seat as objectstack-ai#38769, closed as a duplicate into objectstack-ai#38753 (the
`packagelessHolderRefusal` docblock names it as a known gap, citing
objectstack-ai#38753).
- The hydrated doc row's envelope with one shipper: filed by the seat as
objectstack-ai#38770.

## Tests

Flipped pins (each pinned the FROM the criterion moves):
-
packages/runtime/src/domains/meta-disabled-holder-artifact-door.test.ts:
the review M1 CONTROL that pinned objectstack-ai#34417's FROM is replaced by the
criterion's `[objectstack-ai#34417]` pin.
-
packages/metadata-protocol/src/protocol.packageless-save-address.test.ts:
the objectstack-ai#33904 FROM pins (the read and the delete naming no package
answering P's item) now assert the TO.
-
packages/qa/dogfood/test/action-save-packageless-other-object.dogfood.test.ts
and action-list-packageless-other-object.dogfood.test.ts: the objectstack-ai#33904
FROM legs (read, delete, list) now assert the TO.

New pins:
- `[objectstack-ai#34346]` in
packages/runtime/src/domains/meta-disabled-holder-served-stack.test.ts:
the three bare writes refuse naming the two shippers and nothing moves,
plus a `?package=E` CONTROL.
- `[objectstack-ai#34417]` in meta-disabled-holder-artifact-door.test.ts: both
transports, both registration orders.
- `[objectstack-ai#33127 heal 2]` in
packages/objectql/src/package-scoped-exact-qualifier.test.ts: the enable
while no holder is served, and the hydrator run in that state.
-
packages/runtime/src/domains/meta-environment-action-other-object-33904.test.ts
(new file): every door naming no package, the list, a restart, the
delete, the version, plus CONTROLs with no environment row.
- packages/metadata-protocol/src/protocol.action-list-slot-key.test.ts
(new file, 73c2de8): the list's slot key, cell by cell with each FROM
in the title, plus five CONTROLs (a platform action on the package's
object sharing its slot, a customization on the package's object, an
object-less customization, a platform item with the environment's
object-less row kept one slot, another type slotted by name).
- `[objectstack-ai#33904] P's action OBJECT-LESS, the environment's on \`task\`` in
protocol.packageless-save-address.test.ts (73c2de8): the list names
both, the bare read serves the environment's, the bare delete removes
the environment's row.
- `[objectstack-ai#34258]` in packages/rest/src/meta-qualified-item-route.test.ts: two
disabled holders on the key beside an enabled one on another object
(404, both orders), plus the card's CONTROL (one disabled and one
enabled on the key: served as C's customization).

## Acceptance notes

- objectstack-ai#33127 heal 1 (S1) is not done, on the seat's ruling (objectstack-ai#38754): an
install sends no notice, so there is no trigger for it. With an install
in that state, every door answers 409 naming E and F in all three
states. Only the registry's scoped read of E and the execution list keep
the row until the next unscoped hydration. Reported to the seat.
- objectstack-ai#34258: the name-grain stored-row check (`enabledRowHolds`) stays as
on `main`. A key-grain filter was written and ablated. It turned no pin
red, because a sealed holder's rows are declined first
(`declinesStoredRow`), so it was dropped as unreachable.
- The envelope lookup keeps its earlier answer for two enabled holders
at one key (`protocol-artifact-lookup.action-owner-key.test.ts` CONTROL,
unchanged). The bare read refuses that name before any envelope.
- Rebased over objectstack-ai#38594 (merged), which added `rollback` to the
disabled-holders verb. The two helpers this PR adds
(`enabledHoldersRefusal`, `disabledRowHoldersRefusal`) take every verb
but `rollback`: no rollback door calls them, and the 409 message has no
rollback wording.

## Verification

Head 5db4acc. It adds two commits to 73c2de8: 9910fbc (the contract
review's S3: the platform-action list cell declared in the changeset
bullet and the `environment-action-on-another-object-answers-first`
entry, the count corrected to three cells, three pins and a CONTROL; no
code moves) and 5db4acc (N5: the known-gap note cites objectstack-ai#38753). On them,
under the lock (`VERDICT command-exit 0` each): spec build,
`gen:migration-registry` no diff, spec migrations 209/209, spec
`test:repo` 1608/1608, the two metadata-protocol list and save-address
files 120/120 (the list file 13/13), typecheck of metadata-protocol and
spec; gate families 1 to 81 of the 103 ran on 9910fbc and 82 to 103
plus `check-issue-citations` on 5db4acc (the two differ by one
comment), every one exit 0, `dispatch-gates --ran`: 103 derived, 103
run, 0 NOT-MEASURED; overlap-check `VERDICT clean exit 0` against
`origin/main` 6ba8ddd. On 73c2de8 every CI check passed, `Dogfood
battery (opt-in)` included (66 success, 13 skipped); a new run is owed
on this head.

On 73c2de8, on `main` cb8d853 (after objectstack-ai#38640, objectstack-ai#38594, objectstack-ai#38699 and
objectstack-ai#38712), in this container, heavy runs under
`scripts/pm/os-verify-lock.sh` (shared box).

73c2de8 answers the contract review (S1, S2, N1 to N3): a package's
object-less action is a list key of its own, the two list cells that
moved are measured, pinned and declared FROM and TO, and three text
fixes (the `packagelessHolderRefusal` docblock keeps its known gap; the
bare-write entry's surface excludes a stored package-less row; the
hydrated-doc entry counts a disabled shipper). On it, under the lock
(`VERDICT command-exit 0`, held 1h27m40s): `pnpm build` 123/123;
`gen:migration-registry` no diff; spec migrations 209/209;
metadata-protocol 23813 passed / 45 skipped; runtime, the whole package,
658 files, 12568 passed / 27 skipped; rest 9099 / 351 skipped; objectql
14570; the two dogfood files 6/6; `test:repo` of objectql, rest,
runtime, spec, core and types; typecheck of metadata-protocol, runtime,
rest, spec and objectql; all 103 derived gate families exit 0
(`dispatch-gates --ran`: 103 derived, 103 run, 0 NOT-MEASURED);
overlap-check `VERDICT clean exit 0` against `origin/main` bb86347.

b61bcd2 fixes two CI reds of b0e3f1d, both from objectstack-ai#33904's list slot:
the local helper's name `actionObjectKey` was the objectstack-ai#14878 dead member the
tree-wide repo pins refuse (renamed `actionSlotSuffix`), and slotting
EVERY action by object split a platform item from the environment's
object-less row of its name, so `/actions/_env/lead/approve` served the
platform item instead of 404 (runtime action-package-addressing.test.ts;
bisected with rebuilt dists: `main` and the first three commits green,
616d76d red). On b61bcd2, under the lock (`VERDICT command-exit 0`):
metadata-protocol 23803 passed / 45 skipped; runtime, the WHOLE package,
658 files, 12568 passed / 27 skipped; `test:repo` of runtime, objectql,
rest, spec, core and types; rest 9099 / 351 skipped; the two dogfood
files 6/6; typecheck of metadata-protocol and runtime;
`check:issue-citations`, `check-nul-bytes`, `check:adr-symbol-anchors`,
`check:slot-lookup`, `check:type-check-debt`,
`check:query-options-erasure`, `check:undeclared-dep-imports`, each exit
0; overlap-check clean. The earlier local runtime reading covered
`src/domains` only, which is how this cell was missed.

b0e3f1d (the L1 delta) changes text only: the changeset bullet, the
entry, a pin title and two docblocks. On it, under the lock (`VERDICT
command-exit 0`): spec build, `gen:migration-registry` (no diff), spec
migrations 209/209, the CLI `migrate-meta-engine-guidance` pin 3/3,
`check-adr-0087-registration`, `check-changeset-no-major`,
`check-empty-changeset`, rest `meta-qualified-item-route.test.ts`
439/439, metadata-protocol typecheck, `check:upgrade-guide`,
`check:issue-citations`, `check-nul-bytes`, each exit 0; overlap-check
clean.

<details><summary>Suites</summary>

Under the verify lock: `VERDICT command-exit 0` (held 1h12m59s).

| run | exit | result |
|:--|:--|:--|
| `pnpm install --frozen-lockfile` | 0 | |
| `pnpm --filter @objectstack/spec gen:migration-registry` | 0 | no diff
|
| `pnpm --filter @objectstack/spec exec vitest run src/migrations` | 0 |
5 files, 209 tests |
| `pnpm build` | 0 | 123/123 tasks |
| `pnpm --filter @objectstack/metadata-protocol test` | 0 | 376 passed,
9 skipped files; 23803 passed, 45 skipped tests |
| `pnpm --filter @objectstack/objectql test` | 0 | 641 files, 14570
tests |
| `pnpm --filter @objectstack/rest test` | 0 | 442 files; 9099 passed,
351 skipped tests |
| `pnpm --filter @objectstack/runtime exec vitest run --maxWorkers=2
src/domains` | 0 | 245 files; 7487 passed, 6 skipped tests |
| dogfood, the two files this PR changes
(`action-save-packageless-other-object`,
`action-list-packageless-other-object`) | 0 | 2 files, 6 tests |
| `typecheck` of metadata-protocol, runtime, rest, spec, objectql | 0
each | |

The full dogfood battery is not run locally: this PR's title carries
`!`, so it is owed by the opt-in CI lane (`Dogfood battery (opt-in)`) on
this head. For reference, an earlier full dogfood run on the same
commits over `main` 830ff8b passed: 495 passed and 3 skipped files,
4187 passed and 68 skipped tests.

That earlier run also found three type errors after the rebase onto
objectstack-ai#38594 (the verb above, and an `undefined` narrowing in
`lookupArtifactItem`). They were fixed in the commits that introduced
them, and the runs above are on the fixed head.

</details>

<details><summary>Ablation (dev-ablation.md: commit first, mutate with
ablation-replace, rebuild, dist preflight, run, restore from HEAD, prove
an empty git diff HEAD, rebuild, preflight --absent)</summary>

Run on the branch before the rebuild from `main`. The code is the same,
apart from the two type-only fixes named under Suites, which move no
runtime path.

| arm | mutation | pins red | restored |
|:--|:--|:--|:--|
| objectstack-ai#34346 | the bare-write refusal beside a disabled binding made
conditional (two guards in protocol-save.ts) | runtime `[objectstack-ai#34346]` 4 |
diff empty, marker absent |
| objectstack-ai#34417 | the hydrated environment doc grafts the holder's envelope
again | artifact-door `[objectstack-ai#34417]` 2 | diff empty, marker absent |
| objectstack-ai#33127 heal 2 | the no-holder-served branch and its record made
conditional | objectql `[objectstack-ai#33127 heal 2]` 2 | diff empty, marker absent |
| objectstack-ai#33904 predicate | `holdsEnvironmentOwnAction` answers false |
metadata-protocol 3, runtime 3 | diff empty, marker absent |
| objectstack-ai#33904 list slot | the list slots actions by name again |
metadata-protocol 2, runtime 2 | diff empty, marker absent |
| objectstack-ai#33904 list slot, b61bcd2 | arm A: by name again; arm B: every bound
object joins the slot (the b0e3f1d rule) | A: metadata-protocol 2,
runtime 2, dogfood list 2; B: runtime `action-package-addressing` 1 |
each: `git status --porcelain` empty, rebuilt, marker absent |
| objectstack-ai#33904 list slot, 73c2de8 | an object-less action is no key of its
own again (the b61bcd2 rule) | metadata-protocol 3 (the two object-less
list cells and the object-less pin in packageless-save-address); runtime
0 | `git status --porcelain` empty, rebuilt, marker absent |
| objectstack-ai#33904 delete heal | the bare-slot entry is not retired on delete |
runtime 1 | diff empty, marker absent |
| objectstack-ai#34258 lookup | the one enabled holder at the key no longer lends the
envelope | rest `[objectstack-ai#34258]` 1 (the CONTROL) | diff empty, marker absent |
| objectstack-ai#34258 key | the face's key-grain withhold made conditional | rest
`[objectstack-ai#34258]` 1 | diff empty, marker absent |
| objectstack-ai#34258 stored rows | a key-grain filter on `enabledRowHolds` (since
dropped) | 0: unreachable, see Acceptance notes | diff empty, marker
absent |

The lookup leg was run again after the fix kept the earlier answer for
two enabled holders (the lookup CONTROL in metadata-protocol had gone
red in the full suite): 1 red, restored. An `ablation-dist-preflight
--absent` reading exits 3 while untracked files are in the tree, even
when the dist reading passes; the final readings were taken on a clean
tree.

</details>

<details><summary>Gates</summary>

`node scripts/pm/dispatch-gates.mjs --commands` derived 103 families for
this diff. All 103 ran on 73c2de8, again across 9910fbc and 5db4acc
(see Verification), and before them on 10c011f, after the build above,
each with `< /dev/null`, and every one exited 0. This includes
`check:type-check-debt`, `check:query-options-erasure` and the
`migrate-meta-engine-guidance` CLI pin.

`dispatch-gates --ran`: 103 derived, 103 run, 0 NOT-MEASURED, 0 UNRUN.

`node scripts/pm/overlap-check.mjs`: merges cleanly with `origin/main`
6ba8ddd, `VERDICT clean exit 0`.

</details>

🤖 Generated with [Claude Code](https://claude.com/claude-code)

https://claude.ai/code/session_01ADHkmQmQ1jpFsNcARMbY56

<!-- signed: repo:objectstack#3 · os-steve ·
session_01ADHkmQmQ1jpFsNcARMbY56 -->

---------

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/m tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Address-clash refusal should carry the holding form as data

2 participants