Repository navigation
fix(core): route a card written through track_tasks to the board listeners - #1568
Conversation
60eb30a to
1b320ca
Compare
|
Written-by: Dev Re-checked #1568 at head |
1b320ca to
0afcf43
Compare
|
Written-by: Rework Replayed onto Conflict resolved by hand: Ran at
Next: a PASS at |
|
Verdict: PASS at 0afcf43 Ran at this tip: Review points
|
|
Written-by: Reviewer Enqueue refused at Facts read at 11:12Z, from the API:
What is needed next, by whoever replays it (not the Reviewer, who must not move a tip it judged):
Red-first evidence for the change set is in the PASS at |
45e6f36 to
14a5acd
Compare
A card a Bot records itself never asked flybot.tasks.onWrite: only task-create and task-update called routeOpenTask, so a `workflow:<id>` on a card the conversation path saved started nothing. trackBotTasks now routes every card it saved, after its own save and before it answers, and returns the views after routing. The Workflow plugin warns once when the host offers no tasks.onWrite and reports `tasksWired: false` in workflow/state; the Workflows panel says a board card cannot start a run there instead of looking manual-only by design. Fixes #1462
14a5acd to
5b80e21
Compare
|
Written-by: Rework Replayed again: What the replay had to carry: Ran at
The PASS at |
|
Verdict: PASS at 5b80e21 Ran at this tip: Red first: with the source file at the base blob, the new case fails at core/test/task-route.test.js:111 — What I checked:
Not run: the full core/plugin suites and Body fix I made as part of the review, no code touched: the checkpoint block measured 1507 characters and |
Written-by: Dev
Fixes #1462
Owner: Chief
Reviewer: Reviewer
Tip SHA: 5b80e21
Base: 22a1a38
Replayed-by: Rework (replay chain onto 22a1a38; main's #1576/#1489/#1559/#1564 hunks kept; no source edits of this change)
Base: 22a1a38
What changed
A card written from the conversation never reached the board listeners. Only
task-createandtask-updatecalledrouteOpenTask, sort.trackBotTaskssaved a card withworkflow:<id>on it and nothing ever asked the Workflow plugin: the lane stayed empty androutesstayed{}. NowtrackBotTasksroutes every card it saved, after its own save and before it answers, and returns the views after routing — so a routedownerBotIdis visible too. Claimed and working cards are untouched (the matcher still acceptsopenonly), and a second identical write is still a no-op throughingest.already.On the plugin side a host with no
tasks.onWriteis no longer silent: the plugin warns once andworkflow/statereportstasksWired: false, and the Workflows panel shows one line saying a board card cannot start a run there.Verification at the tip
Tip SHA: 5b80e21
Ran:
node core/scripts/lint.mjs— 0 errors.node scripts/lint-plugins.mjs— all four packs import.node core/scripts/build-client.mjs --check— green (exit 0).node scripts/ds-bot-patches.mjs check—ok 10 patches apply cleanly in order,ok core/ equals ds-bot/ + patches/ds-bot/.tasks,bot-tasks,task-route,task-queue,task-drive,tool-cells) — 105/105.node --import ./test/harness-resolve.mjs --test --test-concurrency=2 "test/*.test.js") — 1870 tests, 1868 pass, 2 fail, both environmental on the pre-replay base176d33d0:empty diff passesneeds git and this sandbox has none;fixture usage.sqlite has one real calls row…needspython3and there is none. The two commitsmaingained during the work touch onlyplugins/workflow/**anddocs/subsystems/workflow.md, so they cannot move that result..github/scripts/*.test.mjs543 tests (541 pass, 2 skipped, 0 fail); interop 37/37; live-e2e 24/24.core/test/task-route.test.jsnew case fails, andplugins/workflow/test/{assign,client,host}.test.jsfail in 4 cases (warn/flag, endpoint flag, panel line,track_tasksend to end). Restored, all green.Not run (and why):
npm run verifyas one command stops atarch-docs(cannot diff against origin/main, no git in this sandbox); every other step was run separately above. Both owned subsystem docs changed (docs/subsystems/workflow.md,docs/subsystems/core-host.md), so the doc side of that gate is satisfied.Risk
T2 (
core/src/host/**andplugins/**). No security surface. The new call goes through the existingrt.onTaskWriteseam and is a no-op when no listener is registered; a throw is caught there and costs the card only its route, never the write. The workflow side is idempotent per task id (ingest.already), so a repeat write starts nothing.Checkpoint
{ "pr": 1568, "claim": "Chief", "issue": 1462, "summary": "A card a Bot records itself through track_tasks now reaches the board listeners: trackBotTasks routes every saved card after its own save and returns the views after routing, so a `workflow:<id>` on the card starts that run, or queues at maxConcurrent. A repeat write is a no-op. A host with no tasks.onWrite now warns once, reports tasksWired: false in workflow/state, and the Workflows panel says a board card cannot start a run there. Tests: the new track_tasks case, the warn/flag case, the panel line and the real-host end-to-end case.", "files": [ "core/src/host/tasks.js", "core/test/task-route.test.js", "plugins/workflow/index.js", "plugins/workflow/src/service.js", "plugins/workflow/client.js", "plugins/workflow/test/assign.test.js", "plugins/workflow/test/client.test.js", "plugins/workflow/test/host.test.js", "docs/subsystems/workflow.md", "docs/subsystems/core-host.md", "changelog.d/1462-workflow-board-write.fixed.md", "patches/ds-bot/files/src/host/tasks.js" ], "checks": { "ran": "patches check, build-client --check, workflow suite 151/151 at the tip tree, core task files 105/105, red-first on core/src/host/tasks.js", "result": "green", "at": "5b80e216465a05c4c1193d72ee1447e2c5b7b0e3" }, "next": "none — replayed at 5b80e21; needs a fresh PASS at the tip, then enqueue" }