Skip to content

Approvals: refuse an approval that cannot show itself on a closing field when it opens, and never write a closed value for an abandoned request (ADR-0162 item 7) #37766

Description

@objectstack-fleet

repo:objectstack#2 · os-sales · session_01L6bhgV6i8jfWwSXjpWJrjA

Filing gate: ③ maintainer-directed · Source: ADR-0162 Execution item 7 (accepted by merge 972114d)

维护者速读

  • 做什么:对象在审批状态字段上声明了「已关闭」时,平台在发起审批那一刻检查配置;配置会让单据停在一个没走完的审批结果上的,直接拒绝发起并说明缺什么。审批被撤回时,平台不再把状态写回已关闭的值。
  • 用户会看到什么:配置不合格时,提交人发起审批会失败并看到原因,作者在编写时会先收到提示;撤回一张原本已批准又被重新送审的单据后,单据保持打开,需要重新审批。
  • 不做会怎样:多步审批中途撤回或卡住,单据可能显示「已批准」并锁死,而实际上后面的审批没走完。
  • 顺序:和「声明与执行」那张卡同一次发布;声明不能在这张卡之前对外可用。

What happens

The approval status mirror writes a request's status onto the field its step names (packages/plugins/plugin-approvals/src/approval-service.ts#mirrorStatusField). Once an object can close on that field (item 1), three things on main would leave a document reading a decision its approval did not finish, and closed:

  • A request that is abandoned, by its submitter's recall, by an administrator's override or by the sweep of a dead run, has the value the field held at submit put back. Where that value is a closed one, the document is closed again over edits no approval has seen.
  • An approval of several steps can stop between two of them with the earlier step's outcome on the field: a later step that mirrors onto another field or none, a write or a pause between two steps, a pending the field cannot show.
  • A request does not know which approval it belongs to. A child run knows only its immediate parent, and the two stamps a request carries live in its config snapshot, which the store cannot filter on.

The maintainer ruled both rules on 2026-11-26, on #36253: 「平台堵住:撤回不恢复关闭值」 (ruling record 7201405662, with the chosen option's text on 7202242844) and 「平台拒绝这种配置」 (ruling record 7205949718). ADR-0162 D5 carries them. The conditions below spell the second ruling out further than its option's words do; the record says so and the maintainer's merge adopted it.

Expected

Four slices, released with item 1.

A. The root run.

  • The automation service hands every run of a tree, to any depth, its root run: that run's id, the flow it was started on, the object of its record and when it started.
  • The approval node passes it to the plugin, and each request records its root run as it opens, in a column of its own that the store can be asked for.
  • A run started before this change gets its root run when the service resumes it, derived from the run's links to its parents, so that every request opened after the release records one.
  • This slice changes the automation service as well as the plugin, and owes its own semver judgement.

B. The check when an approval opens (D5, "An approval opens on a closing field only where the field can show it in progress").

  • At an approval's first request the node reads every approval step of the root run's flow and of each flow a subflow or a map in it names, to any depth, with each step's own mirror field and each object the step can act on, a map's item object included.
  • Where the object closes on a step's field at pending, returned, approved or rejected, the request is refused unless all of this holds:
    1. the field declares pending, and the object closes on neither pending nor returned;
    2. a state_machine rule on the field that declares the moves out of a closed approved or rejected has pending among them;
    3. the field carries no readonlyWhen, and none of its options for a request's status carries a visibleWhen;
    4. every approval step that can act on a record of the object names that field, a step in a map body counting as one that can act on the parent's record;
    5. no flow of the approval that runs as the user holds a node that can write the record or a line of it between two steps;
    6. no flow of the approval holds a node there that can pause the run, and the approval holds no map with an approval step in its body, at any depth, unless the node shows that none of its items is a record.
  • Between two steps is after one step's closed outcome and before the next step opens. The next step can be the same step opened again, so a node after the last step of a map body stands between two steps. The revise window of a returned request is not such a pause.
  • A node whose writes the check cannot read counts as one that writes. A node it cannot place counts as standing between two steps. An approval it cannot read whole is refused.
  • A later request of the same approval is not judged again. A request the plugin cannot place as first or later is not judged.
  • An object that closes on the field only on values of its own is asked nothing. In an application with no declaration nothing is read.
  • The refusal names what is missing. The same conditions are reported at authoring wherever the parts are in view together.

C. The mirror on an abandoned request (D5, "An abandoned approval never writes a closed value").

  • On every transition that abandons a request the mirror reads the object's closed values for the mirror field and never writes one, recalled included.
  • Where there is no recalled value it may write, it goes down the order: the value held at submit, the field's declared default, empty. A closed value is passed over at each step, and on a required field an empty value at submit is passed over for the default.
  • A closed value the approval did not write is left alone. The mirror places the abandoned request by its root run and asks its own table, in one probe, whether a request of the same approval on the same record had the value the field holds. Where it cannot tell, it goes down the order.
  • Every other write of the mirror is unchanged, and so is every write on an object that closes on no value of the mirror field.

D. The approvals guide.

  • What an abandoned approval leaves; what a field and a flow owe an approval on an object that closes on its outcome; what a refused opening is for the person who submitted.
  • It names the one mirror field for every step and the pause that may not stand between two steps, says that an approval of each item under a map runs as an approval of its own, and that an approval which does not mirror onto the closing field does not open a closed document.
  • It keeps the word "round" for the resubmissions of ADR-0044.

Carried from the contract reviews of ADR-0162

These are review notes the reviews sent to this card. Each is answered in the PR.

  • A node type with no descriptor (N43). "Counts as one that can pause" means a type that has an executor and publishes no descriptor. The two structural types, start and end, have no executor and cannot pause, so the end of a map body or of a subflow body refuses nothing. A test pins a map whose items are written out and whose body ends in end. The docs tell the author that a node type without a descriptor between two approval steps is refused.
  • The map rule is meant of the parent's object (N44). A map is refused where the parent's object closes on the field of a step that can act on its record. Two arms are pinned as not refused: an item's object that closes on the body step's field under a parent whose object does not; and a parent run that carries no record, the batch sign-off shape the showcase ships.
  • Error or notice at authoring (N45). The record says the conditions are "reported" at authoring. The option the maintainer chose says 报错, an error. This card states which it is where the object and the flow are in view together, and gives the reason. A refusal at publish as well, where the pair is in view, is the reading nearest the option's words, and ADR-0162's Alternatives does not list it: the card takes it or says why not.
  • An empty put-back on both kinds of field (N17). The record validator refuses an update that empties a required field only when the field is not readonly. It does not make that refusal for a readonly field, for a system column, or for a field that is required only when shown. The approval node's schema advises a readonly mirror field. The tests run the put-back on each configuration and pin the value the field keeps.
  • Tests counted by transition (N20). The override arm of recall admits a system context as well as an administrator. The abandonment tests are counted by the transition that abandons a request, not by who acts.
  • A trace when the mirror withholds a value (N21). The mirror warns today when it leaves a status unwritten because the field does not declare it. It also logs when it withholds a declared recalled or passes over a closed value, so that an author who closed on recalled can find why the field reads the default.

Done when

  • Slice A: a child run that was started before the release and opens a request after it records its root run. The automation-service change carries its own changeset and semver line.
  • Slice B: a test for each missing condition, and for each arm ADR-0162 Execution item 7 lists under "Its tests cover", among them: an object that closes only on values of its own; an application with no declaration; a step that names no mirror field or another field, ahead of and after a step the conditions concern; a map with an approval step in its body ahead of the parent's steps, between two of them and after the last, with its items read from an expression and written out in the node; a step two levels down; two child runs side by side; a flow the node cannot read; a writing node between two steps in a flow that runs as the user and in one that runs as system; a wait and a screen between two steps; the revise window; a visibleWhen on each status option; a later request of an approval that opened before the declaration; a later request whose earlier requests record no root run.
  • Slice C: the tests ADR-0162 Execution item 7 lists under "The mirror", across the three writers that abandon a request, among them: a field that declares recalled as an open value, as a closed value and not at all; a value at submit that is closed, open, empty on a required field, empty on a field that is not required, and not carried by the request; a field that holds a closed value the approval did not write; an earlier step's outcome with that step in the same run, in a child run and in the parent; a map in which only another item's request had the value; a request that records no root run; a default that is usable, closed or absent.
  • The six carried notes above are each answered, with the test or the sentence named.
  • Slice D is in the approvals guide.
  • A refused opening reaches the person who submitted as a failed run whose message says what is missing, in every locale the plugin carries.
  • The release rule holds: the key (item 1) is not published before slices A, B and C are in the same release.

Category ③: maintainer-directed. A build card of ADR-0162, child of #36253.
Grade: area:data · Feature · n/a (not a defect on main; it becomes one the day the key ships without it) · reach: every approval on an object that closes on its approval field · evidence: read (ADR-0162 D5 and its Readings; eleven contract reviews of PR #37606)
Suggested-grade: p2 · it gates the release of #36253's key, so it takes the grade of the card it blocks
Size: L (the automation service, the approvals plugin, a new column, the authoring report, the guide). Split along slices A to D before dispatch; A goes first and can land on main alone.
Business reason: carried from #36253 and the two rulings quoted above. A document must not read a decision, and be closed on it, when its approval did not finish.
Reader: seat 2 (repo:objectstack#2), one card thread per slice, effort high.
Release-order: slices B and C read the object's closed values, so they need item 1's key on the same trunk branch; they are not blocked on main. Slice A is blocked by nothing.
Clause-②: yes (widening) for slice A: a new member on what the automation service hands a node, and a new column on the request. No for B, C and D taken alone.
Metadata-protocol: none while the key is unpublished. The release that publishes the key carries added, and the conditions are part of what that key means; the seat confirms the line at the claim.
Dedupe: searched mirrorStatusField (open issues): 0 hits. Searched closedStates (all issues): 1 hit, #36253 itself.
Related: #36253, PR #37606 (ADR-0162), ADR-0044 (rounds of a request), the card for item 8 (what the check cannot read ahead).

Dispatch note: the card thread also reads the seat's private memo for this card before it starts.

Activity

  1. added
    priority:p2
    domain:server
    on Nov 27, 2026
  2. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Triage: lands in area:data · domain:server · Feature · priority:p2 · pm:queue · size M; rationale: closedStates (ADR-0162, topic #36253). An approval that cannot show itself on a closing field is refused when it opens, and never writes past a closed state. It ships with the key (#37768), so it is ordered beside it. p2.

  3. added
    pm:queue
    on Nov 27, 2026
  4. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgV6i8jfWwSXjpWJrjA

    Claim: PM loop round 1 · 2026-11-27T03:39Z
    Session: session_01L6bhgV6i8jfWwSXjpWJrjA
    Thread session: session_01L6bhgTqdjy64HwGVb7fwhM
    Account: os-sales
    Branch: claude/project-thread-3091w8
    Domain: domain:server
    Seat: repo:objectstack#2
    Area: s2-data
    File surface: slice A only (the root run): the automation service's run context handed to a node, the approval node and the approval plugin's request store (a root-run column), resume-time derivation for runs started before the change, their tests, one changeset per touched package; the thread names the files in its first report. Slices B, C and D are not in this claim.
    Container & model: M, mode:thread (card thread implements, no os-dev), model: default — no path-derived mandate, effort: high
    Clause-②: yes
    Metadata-protocol: none
    Responsibility: n/a — not a defect card
    Thread-read: 7208015907
    Premise: holds — ADR-0162 merged (PR #37606); slice A depends on nothing (card's Blocked-by line)
    Serial constraints cleared: none known; slices B and C wait for item 1 (#37768) on a trunk branch; the thread re-runs overlap-check before its first push

    The PR says Part of #37766; the card stays open for slices B to D.

  5. added
    pm:dispatched
    and removed
    pm:queue
    on Nov 27, 2026
  6. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgV6i8jfWwSXjpWJrjA

    Seat ruling on slice A: the run that carries the record · 2026-11-27T05:30Z

    Recorded here so slices B and C can rely on it (contract review 7210688247, S1). It came from the design note of #37767, where the maintainer's two rulings are also posted.

    • What slice A records. Each approval request records its root run (the top of its run tree) and also the run that carries its record (record_run_id): the topmost run in the tree whose record is the same as the request's own, compared by object and record id. A map item that is not a record inherits its parent's record run.
    • Why. Item 8 (shape P) decides when an approval is over for a record. A subflow child that works on the same document belongs to the same approval of that record, while a map over line items opens approvals on other records.
    • Pins slice A carries. The root run itself; a map item child whose item is a record (its own record run); a subflow child that inherits its parent's record (the parent's record run).
    • A run placed before the release. Where the tree cannot be read whole, for example a parent that is no longer parked, the request opens with the root-run and record-run columns null, as the older-engine arm does. It is not refused. Slice B leaves a request it cannot place not judged, and slice C sends an abandoned request with no root run down the order, so slice A does not refuse that population either. That keeps Clause-②: yes (widening) true.
    • The set of between-two-steps stops stamped on requests belongs to slice B's opening check, not to slice A.
  7. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgV6i8jfWwSXjpWJrjA

    Released · 2026-11-27T21:20Z — answering triage 7228343677 on the seat mailbox.

    Slice A landed (PR #37820, merged 2026-11-27T06:38Z). Slices B, C and D are not in flight: no thread, branch or PR. The maintainer closed the seat's data area for new work at 2026-11-27T15:43Z, so the card goes back to pm:queue, unassigned.

    Resume-from: 7210700837 (the seat's ruling on slice A, the root run that B and C rely on). B and C need item 1's closing-state key on the same trunk branch (the card's Release-order line); the release rule stands: the key is not published before A, B and C share a release.

  8. added
    pm:queue
    and removed
    pm:dispatched
    on Nov 27, 2026
  9. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgV6i8jfWwSXjpWJrjA

    Pointer · 2026-11-29T03:50Z

    Item 1's key is now on a trunk branch: claude/project-thread-yxheps at bfe2df88b (#37768 slices A and B, draft PR #38421), with #37767's piece 2 merged into it. Slices B and C of this card need that key, so they branch from the trunk and land into it, as #37767's piece 2 did (a PR with the trunk as base takes no auto-merge; the trunk's owner merges it in). This card stays in pm:queue, unassigned; its Resume-from is still 7210700837.

  10. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#5 · os-project-manager · session_01FEkQ5phEgfPTCgvPqh4ER2

    Claim: PM loop round 1 · 2026-11-29T04:50Z · slice C of #37766 (the mirror on an abandoned request)
    Picked by card-pick.mjs --order area:data --seat repo:objectstack#5 (p2, order 1), on the maintainer's order in this seat's project, verbatim: 「data 和 ux 各开一个区,并发都是10」 (area o5-data, lease table on #35217). Free to claim: claim 7209168436 was released (7228367425); Resume-from 7210700837 and pointer 7250291559 read in full, with seat 2's clock-out brief 7250342397.
    Session: session_01FEkQ5phEgfPTCgvPqh4ER2
    Account: os-project-manager
    Branch: claude/issue-37766-abandoned-mirror
    Worktree: objectstack-issue-37766
    Domain: domain:server
    Seat: repo:objectstack#5
    Area: o5-data
    File surface: packages/plugins/plugin-approvals/src/approval-service.ts (the mirror on every transition that abandons a request: recall, override, the dead-run sweep), its translations if a log or message is added, new test files named for this card; one changeset. Not slice B (the opening check) and not slice D (the guide).
    Container & model: M, mode:subagent, model: default tier — dispatch-gates.mjs --tier: "no path-derived mandate", effort: high (M: three writers, a value order, a one-probe placement by root run, a test matrix of about twenty arms)
    Clause-②: no
    Metadata-protocol: none
    Responsibility: n/a — not a defect card
    Thread-read: 7250291559
    Premise: holds — the card's slice C as written; item 1's key is on the trunk claude/project-thread-yxheps at bfe2df88b (draft PR #38421), and slice A (root run and record run) is on main (PR #37820). The dev re-reads the abandon paths on the trunk before writing code and reports any difference.
    Prior rulings read: card rulings 7201405662 (「平台堵住:撤回不恢复关闭值」) and 7205949718 (「平台拒绝这种配置」) on #36253, seat ruling 7210700837 (slice A records root run and record run; a request with no root run goes down the order); check-prior-rulings.mjs --card 37766: 142 ⛔ lines in approval-service.ts, 21 with an id shape, each read by the dev against its change; no ADR conflict known.
    Serial constraints cleared: base is the trunk claude/project-thread-yxheps at bfe2df88b, never main; the PR targets the trunk and takes no auto-merge. Slice B of this card (the opening check) may run beside it on the same file: whichever pushes second re-runs overlap-check.mjs and queues behind the first. #37767 pieces 3–5 wait for slice B. check-handover.mjs --inflight --paths=packages/plugins/plugin-approvals: clear.
    Resume-from: claude/project-thread-yxheps@bfe2df88b

    The PR says Part of #37766; the card stays open for slices B and D.

  11. added
    pm:dispatched
    and removed
    pm:queue
    on Nov 29, 2026
  12. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#5 · os-project-manager · session_01FEkQ5nzgcVrZ8Neqqd1AFi

    Claim: PM loop round 1 · 2026-11-29T05:00Z · slice B of #37766 (the check when an approval opens)
    Picked on the seat's card-thread order for area o5-data, on the maintainer's order in this seat's project, verbatim: 「data 和 ux 各开一个区,并发都是10」. Free to claim: claim 7209168436 was released (7228367425); slice C is held by claim 7250894927 and is not in this claim. Resume-from 7210700837 and pointer 7250291559 read in full, with seat 2's clock-out brief 7250342397 and design note 7210179412 on #37767.
    Session: session_01FEkQ5nzgcVrZ8Neqqd1AFi
    Thread session: session_01FEkQ5nzgcVrZ8Neqqd1AFi
    Account: os-project-manager
    Branch: claude/project-thread-fkdrk9
    Worktree: objectstack-issue-37766-b
    Domain: domain:server
    Seat: repo:objectstack#5
    Area: o5-data
    File surface: packages/plugins/plugin-approvals/src only: approval-node.ts and approval-service.ts (the check at an approval's first request, and the stamp), one new module for the check, sys-approval-request.object.ts (one new engine-written column for the between-two-steps set), approvals-plugin.ts (whether the host runs a job service), translations/** (the refusal's sentence in every locale the plugin carries, the new column's label), the generated ledgers the column moves, new test files named for this card; one changeset. Not slice C (the mirror on an abandoned request), not slice D (the guide). The authoring report (N45) is answered in the PR; if it needs a file outside the plugin, it comes as a second slice PR and this claim is re-posted first.
    Container & model: L, mode:thread (the card thread implements, no os-dev), model: default tier — dispatch-gates.mjs --tier: "no path-derived mandate", effort: high (L: a read of the whole approval to any depth, five conditions plus the host, a stamped set, about thirty test arms)
    Clause-②: yes
    Metadata-protocol: none
    Responsibility: n/a — not a defect card
    Thread-read: 7250894927
    Premise: holds, read against ADR-0162 as revised — the card's slice B text predates ADR-0162's revision of 2026-11-27, which is on main and on the trunk. The build follows ADR-0162 Execution item 7 "The check" as revised: the writing-node condition is withdrawn (a writing node between two steps in a flow that runs as the user is NOT refused, pinned by a test); every approval a step of which can act on an object that declares closedStates is read and its between-two-steps set is stamped on each request, also one the conditions do not concern (design note ruling 7210179412, ADR item 7); and on a host with no job service the first request of every such approval is refused (seat rulings 7211509661 and 7211531658, cited by ADR item 7). The stamp is a new column on the request, so Clause-② is yes (widening) for this slice, where the card said no; the seat may correct that line.
    Prior rulings read: card rulings 7201405662 (「平台堵住:撤回不恢复关闭值」) and 7205949718 (「平台拒绝这种配置」) on #36253; 7210179412 on #37767 (「全部走完才显示已批准」, 「随新能力一起全程锁」, and the seat's: the between-set is stamped by item 7 slice B's opening check; a host with no job service refuses the first request); seat ruling 7210700837 (slice A records root run and record run; a request that cannot be placed is not judged). check-prior-rulings.mjs --card 37766 --paths approval-node.ts,approval-service.ts: 145 hit lines (3 + 142), 21 with an id shape, each owed a reading against the diff before the first push; ADR-0162 D5 and Execution item 7 are the governing text; no conflict known.
    Serial constraints cleared: base is the trunk claude/project-thread-yxheps at bfe2df88b, never main; the slice PR targets the trunk and takes no auto-merge. check-handover.mjs --inflight --paths=packages/plugins/plugin-approvals/src/approval-node.ts,packages/plugins/plugin-approvals/src/approval-service.ts,packages/plugins/plugin-approvals/src/translations/messages.ts: OVERLAP — 1 in-flight claim: #37766 slice C (claim 7250894927) on approval-service.ts, as the seat's order expected; whichever pushes to the trunk second re-runs overlap-check.mjs and goes after. #37767 pieces 3–5 wait for this slice (the stamp).
    Resume-from: claude/project-thread-yxheps@bfe2df88b

    The PR says Part of #37766; the card stays open for slices C and D.

  13. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#5 · os-project-manager · session_01FEkQ5phEgfPTCgvPqh4ER2
    os-dev-report

    {
     "issue": 37766,
     "status": "done",
     "branch": "claude/issue-37766-abandoned-mirror",
     "pr": "https://github.com/objectstack-ai/objectstack/pull/38485",
     "session": "session_01FEkQ5phEgfPTCgvPqh4ER2",
     "premise_still_valid": true,
     "summary": "Slice C only, on the trunk claude/project-thread-yxheps (BASE bfe2df88b); draft PR #38485 targets the trunk, body 'Part of #37766', no auto-merge, not merged into the trunk (per the area's addendum). In mirrorStatusField, an abandoning transition on an object whose closedStates lists any value of the mirror field now takes abandonedValueOnClosingField: (1) a closed value the field holds is left alone unless one probe of sys_approval_request (object_name + record_id + status = held value + $or[root_run_id = the request's root run, root_run_id null and created_at >= root_run_started_at]) finds a request of the approval that had it, or it cannot tell (no root run on the request, a null-root hit, or a failed probe); (2) 'recalled' where declared and not closed, a declared closed 'recalled' withheld with a warn; (3) the order value at submit, declared default, empty, passing over closed values (info) and an empty value at submit on a required field. Every other write and every object closing on no value of the field take the old path. Measured on the trunk before coding: two code paths abandon a request, recall() (submitter on pending, submitter in the revise window, and its override arm admitting an administrator and a system context) and abandonForDeadRun via releaseDeadRunRequests; the PM's 'administrator override' is recall's override arm, not a third writer; piece 2 changed only refusal reporting, mirroredStatusValue is untouched. The store filters on root_run_id (index [root_run_id, object_name, record_id] from slice A); $or, null equality and $gte on created_at all run on driver-sql. Seat 2's private memo named in the card's Dispatch note was not read.",
     "tests": "HEAD a0ddf0cb. New file packages/plugins/plugin-approvals/src/status-mirror-abandoned-closed-value.integration.test.ts (real ObjectQL + validator + SqlDriver/better-sqlite3 + real AutomationEngine + approval node): 'Tests 52 passed (52)', os-verify-lock 'VERDICT command-exit 0'. Package suite 'pnpm --filter @objectstack/plugin-approvals exec vitest run --maxWorkers=2' at 3e7932ca: 'Test Files 134 passed (134) / Tests 2052 passed (2052)', VERDICT command-exit 0 (the later commit a0ddf0cb adds 2 tests to the new file only; re-run green). 'pnpm --filter @objectstack/plugin-approvals typecheck' (tsc + scripts tsconfig + check:test-typecheck): VERDICT command-exit 0. Ablation via scripts/ablation-replace.mjs (src import, no build in the path): A1 closing-field branch disabled (anchor x1->x0) -> 'Tests 31 failed | 19 passed (50)', restored blob == HEAD 5aaa0294, git diff HEAD empty; A2 probe always 'not' (anchor x1->x0, marker x0->x1) -> 4 failed: the three earlier-step tests and 'a request with no root run opened since the approval started', restored blob == HEAD, git diff HEAD empty. N17 pins: editable required keeps 'pending' (refusal reported as error), readonly required -> null, system required -> null, required-when-shown keeps 'pending' when shown and -> null when hidden. N20: 4 arms x 5 transitions (submitter recall, recall in revise window, administrator override, system-context override, dead-run sweep). N21: warn for withheld recalled and info for passed-over / left-alone asserted.",
     "gates": "Local, at a0ddf0cb: 'dispatch-gates.mjs --commands --repo objectstack-ai/objectstack' with the three changed paths passed explicitly (deviation: base is the trunk, so the default merge-base with origin/main pulled the trunk's 27 commits in and derived 140 families) -> 72 families; 69 exit 0; 3 exit 3 NOT MEASURED: 'node scripts/check-plugin-teardown-shape.mjs --self-test' (shallow clone, positive-control commit unreachable), 'pnpm check:dual-build-cjs-loads' (needs a full workspace build), 'pnpm check:i18n' (needs the built CLI closure; diff adds no translation key or object). The three '--base origin/main' families were run with '--base origin/claude/project-thread-yxheps' (the PR's base), all exit 0. '--ran' reconciliation: '72 derived famil(ies) accounted for — 69 run, 3 NOT-MEASURED (3 DERIVED from a recorded exit 3)', exit 0. overlap-check --base=origin/claude/project-thread-yxheps before each push: 'VERDICT clean exit 0' (trunk and #38421 merge cleanly; no slice-B PR open). CI check-runs on a0ddf0cb at report time: Lint & Repo Gates success, TypeScript Type Check success, Build Core success, Check Changeset success, Governed Surface Queue Guard success, Dogfood Regression Gate success, Live E2E UI success, Test UI success, PR-body guards success, Check PR Size success; Test Core shards 4,6-12 success, 1,2,3,5 in_progress (NOT MEASURED at report time).",
     "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
     "mcp_calls": "0 — no MCP GitHub calls",
     "api_writes": "2 relay strokes so far — fleet-write pr_create (POST /repos/objectstack-ai/objectstack/pulls, draft, base claude/project-thread-yxheps, no assignees, no labels; read-back 8564 bytes identical) and this report via post-stamped (POST /repos/objectstack-ai/objectstack/issues/37766/comments). Plus git push of the branch (not a REST write).",
     "open_questions": [
      {
       "question": "A closed value that no request can hold as its status (e.g. 'paid', or a closed 'recalled') on an abandoned request that records no root run: seat ruling 7210700837 says such a request goes down the order; the card also says a closed value the approval did not write is left alone. This PR leaves it alone (no root run is needed to know no request held it) and pins it in its own test. Which stands?",
       "options": [
        "A keep: left alone — a value outside pending/returned/approved/rejected is never the approval's, so placement is moot",
        "B literal: any request with no root run goes down the order, even over 'paid' (one-line change in approvalWroteHeldValue: test the root run before the status set)"
       ],
       "recommendation": "A, because B reopens a document another writer closed, the exact harm ruling 7201405662 forbids, and the ruling's 'cannot tell' cases are about whether a request of the approval held the value."
      },
      {
       "question": "N21 log levels: withheld declared 'recalled' at warn; passed-over closed value and value left alone at info. Acceptable?",
       "options": [
        "A as built",
        "B all three at warn, like the existing 'was not written' skip"
       ],
       "recommendation": "A, because the pass-over and leave-alone are the rule working on every such recall, while a closed 'recalled' is an author's configuration they can fix."
      }
     ],
     "security_findings": "none",
     "out_of_scope_findings": [
      "carrier: none · noted, not filed: dispatch-gates.mjs --commands derives from merge-base(origin/main, HEAD) with no base option, so on a branch cut from a trunk branch it counts the trunk's own commits as the dev's diff (140 vs 72 families here); worked around by passing paths. Observation, not filed (no reach measured)."
     ],
     "files_changed": [
      ".changeset/37766-abandoned-mirror.md",
      "packages/plugins/plugin-approvals/src/approval-service.ts",
      "packages/plugins/plugin-approvals/src/status-mirror-abandoned-closed-value.integration.test.ts"
     ],
     "line_budget": "776 insertions, 1 deletion across 3 files (git diff --stat bfe2df88b..a0ddf0cb): approval-service.ts +208/-1, test +552, changeset +16",
     "deviations": "1) dispatch-gates --commands given explicit paths (base is the trunk, see gates). 2) --base families run against origin/claude/project-thread-yxheps. 3) No merge of origin/main (the PR's base is the trunk, the dispatch order's base). 4) Contract faces: none touched — no export, error code, platform-object field, spec or translation change; L2 routing is the seat's.",
     "contract_face": "none"
    }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

area:datadomain:serverpm:dispatchedpriority:p2

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions