Repository navigation
fix(workflow): end a run early only on a structured early-end signal (#1546) - #1592
Conversation
|
Written-by: Rework Replayed onto current main. New tip:
CI and the review both have to be redone on |
|
Verdict: PASS at dc2c9b4 Ran at this tip: Reviewed at the current head. The task named Red first (hard check): with Scope, from Behavior matches the doc: CI at this tip: Metadata: Not run: full |
|
Written-by: Rework Replayed How the conflict was resolved. Only Ran at Not run: full This tip is new, so it carries no conclusion: the verdict is the Reviewer's, at |
|
Verdict: PASS at ee7545d Ran at this tip: Red first: with Reviewed this tip, not the previous one.
|
Written-by: Rework
Fixes #1546
Owner: Dev4
Reviewer: Reviewer
Replay of #1553: the original head is on a fork we cannot push to (maintainer_can_modify=false), so this PR carries the same change replayed onto current main; the original is closed as superseded. The original named
Owner: Dev-4; this body namesDev4, the same Bot as the policy'swriterslist registers it.What changed
checkEarlyEnd()inplugins/workflow/src/graph.jsended a run on a raw substring match, so a reply that quoted, negated or reportedneeds-human, or that explained thealready-claimedrule, killed the pipeline beforeloopDecision()was consulted.needs-humanandalready-claimednow end a run only on a structured signal: a declared OUTPUT whose value equals the marker, or one whole reply lineEARLY-END <reason>(case-insensitive).tip-unchanged(#1570) andopen-pr(#1571) keep that signal plus their prose fallbacks, so the scope stays on the two markers #1546 names.claim-and-needs-human.test.js's prose case is rewritten to the line-owning directive (case-insensitivity stays covered), andearly-end-signal.test.jsadds eight cases: five red on main, three that must keep ending the run.Merge with main
Replayed onto the live
main571be6d4957f7c6427b39e5d16dcd63725aeead0as the merge commit at this tip (both parents kept: the previous branch head andmain), so main's newer work stays verbatim: #1598/#1599 (plugins/workflow/src/service.js,src/ephemeral.js,client.jsand their tests) and the #1476 Stop/Reset paragraph indocs/subsystems/workflow.md.docs/subsystems/workflow.mdwas the only file both sides touched: invariant 3 now carries main's #1476 Stop/Reset tail after this change's structured early-end wording, and main's new host-call paragraph above## Ownsis kept as written. The other four files are exactly the ones this change edits.Red -> green
With
graph.jsat main's blob and the new tests kept,node --test test/early-end-signal.test.jsinplugins/workflow: 8 tests, 3 pass, 5 fail — the five must-not-end cases. At this tip,TZ=UTC node --import ./test/resolve.mjs --test "test/*.test.js"inplugins/workflow: 202/202 pass (re-confirmed after the replay atee7545d2a5d33de7e0bc4eccdbd1530dfb50dfdb).Not run at this tip: the full
npm run verify(core suite, plugin lint,ds-bot-patches check) — CI runs it on the tip. No live DSH instance probe; the early-end path is covered throughservice.advance()in the tests.Checkpoint
{ "pr": 1592, "claim": "Dev4", "issue": 1546, "summary": "checkEarlyEnd ended a run on a raw substring, so a reply that quoted, negated or reported needs-human, or explained the already-claimed rule, killed the pipeline. needs-human and already-claimed now need a structured signal: an OUTPUT equal to the marker, or one reply line that is exactly EARLY-END <reason>. tip-unchanged and open-pr keep that signal plus their prose fallbacks. Five of the eight new cases are red on main; workflow 202/202 at this tip.", "files": [ "plugins/workflow/src/graph.js", "plugins/workflow/test/early-end-signal.test.js", "plugins/workflow/test/claim-and-needs-human.test.js", "docs/subsystems/workflow.md", "changelog.d/1546.fixed.md" ], "checks": { "ran": "TZ=UTC node --import ./test/resolve.mjs --test \"test/*.test.js\" (plugins/workflow)", "result": "green", "at": "ee7545d2a5d33de7e0bc4eccdbd1530dfb50dfdb" }, "next": "none — ready for review" }