Skip to content

fix(plugin-approvals): an expression approver id that names no account adds no phantom slot - #27926

Merged
objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/project-thread-dm9v3o
Oct 30, 2026
Merged

objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/project-thread-dm9v3o

Conversation

@objectstack-fleet

Copy link
Copy Markdown
Contributor

Requested by Elon · project thread

Fixes #27879

维护者速读

What changes

Why

#27397 and #27752 closed the phantom-slot path for user and field approvers. The expression branch still handed an id no account carries straight to the slate: the request opened on a slot nobody could take, with no warning and no onEmptyApprovers.

Verification

  • Measured on main first: of the 5 new cases, 2 were red (the warning/no-slot case and the emptied-slate fallback case), and the 3 pins (live ids quiet, failed read keeps the slot, dead delegate falls back to the id) were green.
  • Ablation: disabling the new check reds exactly those 2 cases. Restored: all green.
  • plugin-approvals full suite: 105 files, 1352 tests pass. Five existing cases routed expression slots to ids their test double's directory did not carry (old_reviewer, u3, u4, u6, u7, u8). Their fixtures now staff those accounts, test-only, as fix(plugin-approvals): a field approver id or an out-of-office delegate that names no account adds no phantom slot #27852 did for field.
  • Every dispatch-gates --commands family plus pnpm lint: reported on the card thread.

Clause-②: no
Metadata-protocol: none

Human Minimum

  • 1. Schemas start as Zod; packages/spec holds no runtime logic.
  • 2. Every name I added uses the casing for its kind.
  • 3. No formatter ran; pnpm lint passes.
  • 4. One issue, one branch off an up-to-date main, one pull request.
  • 5. A change that publishes carries a changeset, and both declaration lines are filled in here and in the changeset.
  • 6. packages/spec touched: its generated artifacts are regenerated and committed. (not touched)
  • 7. No hand edits to content/docs/references/, packages/*/CHANGELOG.md or content/docs/releases/.
  • 8. Title, body and comments are in English.
  • The Before Submitting list in CONTRIBUTING.md is done.

🤖 Generated with Claude Code

https://claude.ai/code/session_016WV4czYgbnZDQp3qTKCWae

…t no longer opens a slot

An `expression` approver resolved as users (`resolveAs: 'user'`, the
default) now asks the same `namesNoAccount` predicate the `field` branch
asks: an id no account carries warns "expanded to nobody" and adds no
slot, so an emptied slate reaches the node's onEmptyApprovers. A failed
directory read keeps the slot; a dead out-of-office delegate routes back
to the id.

Co-authored-by: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016WV4czYgbnZDQp3qTKCWae
@github-actions github-actions Bot added size/m documentation Improvements or additions to documentation tests tooling labels Oct 30, 2026
@github-actions

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

1 anchor(s) derived from 1 changed package(s); no hand-written page names any of them, so this run has nothing to list — not a clean bill of health. This check sees only pages that NAME a derived anchor: one that documents this change in prose, or enumerates it in an authoring dialect, names none and stays invisible to it on every run.

What this run could not see
  • the SDK route bridge reached 58 of 210 client-bound route-ledger rows — the other 152 have no registrar path: tail to select them, so pages documenting THEIR client methods cannot appear above, on this or any run. Of those 152: 0 are remediable by widening that discovery convention (an in-repo file declares the path; the convention did not scan it); 55 are structural — on a ledger where NOT ONE row is declared in-repo, so no discovery change reaches them at any price; 97 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 — 6 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 d4064cc159ce0804091278eb964d8da8e05dec87 → packageMentionDocs.

Which tree this was computed on

This run read content/docs from 1094deee484df08cfe1df4f4f7de062220aa9a63 — the merge of head 188c4d0fa760dbc884bdcad1be74fc7a9a092d81 into base d4064cc159ce0804091278eb964d8da8e05dec87, 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 1094deee484df08cfe1df4f4f7de062220aa9a63 && git checkout 1094deee484df08cfe1df4f4f7de062220aa9a63
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin d4064cc159ce0804091278eb964d8da8e05dec87 188c4d0fa760dbc884bdcad1be74fc7a9a092d81 && git checkout -B drift-repro d4064cc159ce0804091278eb964d8da8e05dec87 && git merge --no-ff 188c4d0fa760dbc884bdcad1be74fc7a9a092d81

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

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

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:server#3 · os-elon-musk · session_016WV4czuTWNgKR22fKv7jia

Seat ACCEPT · PR #27926 · head 188c4d0fa760dbc884bdcad1be74fc7a9a092d81 · 2026-10-30T04:30Z

维护者速读

This change covers an expression approver resolved as users (resolveAs: 'user', the default). The approver now keeps a slot only for an id that an account carries. An id with no account logs the shared "expanded to nobody" warning and adds no slot. If that leaves the slate empty, the node's onEmptyApprovers decides. This is the third sibling of #27397 (user) and #27752 (field), and it reuses the same namesNoAccount predicate. A failed directory read keeps the slot. A dead out-of-office delegate still routes back to the id.

席位核对

  • Shape: draft → main, Fixes #27879.
    • Four files: approval-service.ts (+14 / −2, in the resolveAs === 'user' branch only), two test files, and a changeset.
    • check-governed-merges --pr 27926: NOT governed, +117 / −5.
  • Read of the diff: the guard has the same shape as the field path. It applies only when the out-of-office lookup returned the id unchanged, the id is not a typed reference (:), and the directory says no account carries it. The graph kinds (department / position / team) are untouched.
  • Tests: 5 new cases. 2 were red on main, and the ablation reds exactly those 2. The other 3 are preservation pins.
  • Declarations: Clause-②: no, Metadata-protocol: none, patch. No published surface moves, so no contract review is owed.
  • Gate check-runs on this head: 48 total, 35 success, 13 skipped by the path filter, 0 failed. mergeable_state: clean.
  • Landing: Tier S, under the maintainer's landing grant for this term (2026-10-29 22:05Z, seat thread). Ready + auto-merge through the relay.

ACCEPT

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review October 30, 2026 04:31
@objectstack-fleet
objectstack-fleet Bot enabled auto-merge October 30, 2026 04:31
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Oct 30, 2026
Merged via the queue into main with commit be16c6a Oct 30, 2026
49 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/project-thread-dm9v3o branch October 30, 2026 05:23
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

Projects

None yet

2 participants