Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
spec(FIX-1629): BR-25 names the substrate's reasons as observed; C1 g…
…ains the retryable failTask leg

After a retrying failTask re-queues a held row, the displaced worker's
completion declines `disallowed` and its failure `lost-claim`, neither
writing (task-tool-actions.test.ts on #2347).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014LohgYyHsXCYQd6kABH11N
  • Loading branch information
claude committed Sep 29, 2026
commit 30cbd42315f4cfb51bb2aeecd538aa177e7c9780
2 changes: 1 addition & 1 deletion specs/issues/FIX-1629/BUSINESS-RULES.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ When → then → proved by. CI = unit test in the owning package. VG = the goal
|---|---|---|---|
| BR-17 | A flow spreads `taskToolActions(board)` into `actions` | It gains the eight task tools as actions, named `<tool>_<board suffix>`, each running the same guarded verb a model's tool does. A request- or sequencer-backed board is refused when `taskToolActions` is called, naming its backing: its tasks don't outlive the request, so a later action could never find them | CI |
| BR-18 | One of them targets a settled task, or an illegal move | Refused by the verb, returned as a value | CI |
| BR-25 | `completeTask`, `failTask` or `cancelTask` runs as an action on a row a live worker holds | It runs with no claim, as a coordinator's call does today, and lands if the transition is legal. The worker's own later result is refused and dropped, with the reason the task substrate already gives: `terminal` when the action finished the row, `lost-claim` when a `failTask` with retries left returned it to pending. An illegal move on a held row (`blockTask` among them) is BR-18's | CI |
| BR-25 | `completeTask`, `failTask` or `cancelTask` runs as an action on a row a live worker holds | It runs with no claim, as a coordinator's call does today, and lands if the transition is legal. The worker's own later result is refused and dropped, with the reason the task substrate gives ([What a write reports](../../../apps/docs/docs/orchestration/task-substrate.md#what-a-write-reports)): `terminal` once the action finished the row; after a `failTask` with retries left sent it back to `pending`, `disallowed` for the worker's completion and `lost-claim` for its failure | CI |
| BR-19 | A channel declares `boardActions: true` | Each of its boards gets the eight actions. Without it, the channel's public actions are exactly today's | CI |
| BR-26 | A channel board's action is invoked while addressing any session but that channel's | Refused by name before the ledger is read, the same check `fileTask` and `readBoard` make. Channels share one flow, so the action map alone does not fence them | CI |
| BR-20 | `boardActions` is anything but `true`, `false` or absent | Refused at bind, by name, like any other bad value in the closed key list (which grows from six keys to seven) | CI |
Expand Down
5 changes: 3 additions & 2 deletions specs/issues/FIX-1629/DECISIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,9 @@ It comes down to your screenshot: off, the board you asked about stays read-only
visible. A refusal never shows as success.
- **An action's settlement overrides a worker's claim.** An action has no claim ticket, so it
settles as a coordinator does today: legal transitions only, no ownership check. The holding
seat's later result is refused and dropped (`terminal` once the action finished the row, `lost-claim` when a retrying `failTask`
returned it to pending). Clearing a stuck row is the debugging job, and
seat's later result is refused and dropped: `terminal` once the action finished the row; after a
retrying `failTask` sent it back to `pending`, `disallowed` for the seat's completion and
`lost-claim` for its failure. Clearing a stuck row is the debugging job, and
refusing would need a new substrate guard. It is why channel exposure stays opt-in.
- **Durable boards only.** A request- or sequencer-backed ledger is gone before the row's action
runs, so `taskToolActions` refuses those backings by name, as `unparkAndDrain` does.
Expand Down
2 changes: 1 addition & 1 deletion specs/issues/FIX-1629/PLAN.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ S5/S6 and S1–S4 are independent; land orchestration first so the DevTool tests
| ID | After | Passes when |
|---|---|---|
| C0 | S5 | **Premise first:** a task-tool handler (it declares `parentStateSchema`) runs as a flow-action root in a `fsdev run`/engine test and writes the ledger, **and** that request's root `block_trace` carries the handler's `{ ok, error }` as inline output on the session's items. If either fails, wrap each in a one-step sequencer inside S5 (its trace refs the handler's) — no engine change |
| C1 | S5 | Each of the eight actions runs its verb on a row **filed by an earlier request**; a settled-row `cancelTask_x` returns `declined`/`ok:false`; a request-backed handle is refused by name; `completeTask_x` on a row a worker holds lands, and that worker's own settlement then declines `terminal`, because the action finished the row (BR-17, BR-18, BR-25); `blockTask_x` on a held row is refused as an illegal transition (BR-18) |
| C1 | S5 | Each of the eight actions runs its verb on a row **filed by an earlier request**; a settled-row `cancelTask_x` returns `declined`/`ok:false`; a request-backed handle is refused by name; `completeTask_x` on a row a worker holds lands, and that worker's own settlement then declines `terminal`; `failTask_x` on a held row with retries left returns it to `pending`, and the worker's later completion declines `disallowed` and its failure `lost-claim`, neither writing (BR-17, BR-18, BR-25); `blockTask_x` on a held row is refused as an illegal transition (BR-18) |
| C2 | S6 | Channel with `boardActions: true` lists 8 × boards more public actions; without it the public map equals today's snapshot; a bad value is refused at bind by name; channel A's action invoked on channel B's session is refused and A's ledger is unchanged (BR-19, BR-20, BR-26) |
| C3 | S3 | Qualification: required `taskId` string in, optional `taskId` out, suffix scoping, unsuffixed on every board; with two boards A and B, `answer_<A>` shows on A only and a generic `answer` on both (BR-9, BR-10) |
| C4 | S1/S2 | jsdom: collapsed order, expand by click and keyboard, every BR-4 field present when set and absent when not, JSON folded and equal to the task, open row survives an update, long unbroken token contained (BR-1, BR-3–BR-7) |
Expand Down
Loading