Repository navigation
fix(workflow): tell a node the OUTPUTs its edges read - #2670
Merged
Merged
Conversation
A node was only handed the outputs it declared, while the outgoing edges read OUTPUTs too — so a graph whose Triage declares none and whose edges branch on `state` never told the node to print that line, and every run of that shape failed on `Missing OUTPUT state`. `stepBody` now hands the declared ports plus the outputs its edges read (`edgeOutputs`, next to `missingVerdicts`), and the handoff spells the values an edge compares against, so a step can answer the gate it is judged by. Written-by: Dev
Collaborator
Author
|
Verdict: PASS at 6c9eca5 Ran at this tip: Red first, both ways. Reverting 审查要点:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Written-by: Dev
Fixes #2669
Owner: Dev
Reviewer: Reviewer
What changed
stepBody()hands each step its declared outputs plus the outputs its outgoing edges read (edgeOutputsinsrc/graph.js, next tomissingVerdicts), and the handoff spells the values an edge compares against:OUTPUT state: <one of: ready>.missingVerdictsis untouched — a step that prints nothing still fails the gate; it is just no longer asked for a line it was never told to print. Docs: one sentence indocs/subsystems/workflow.md§5, fragmentchangelog.d/2669-edge-outputs.fixed.md.Red first
At
3b8d4e8cthe new tests fail (plugins/workflow, exit 1, pass 33 / fail 4):Ran at this tip: 6c9eca5
The working copy the runs used was fetched back file by file from this ref and matches (7/7); the ship step re-fetched the same seven files at the tip and re-ran the brief's four-file set.
Not run
npm run verify— the brief runs one suite at a time on this box, and nocore/file is in this diff.build-client.mjs --check/ds-bot-patches.mjs check— nocore/change.arch-docscheck — no oxlint binary and nogiton this box; the owned pagedocs/subsystems/workflow.mdis updated in the same commit.Out of scope (follow-ups, not touched here):
missingVerdictsalso reads a loop edge'suntil.output, andreadStepResultstill drops anOUTPUTline a node prints for a name outside its declared ports.Checkpoint
{ "pr": 2670, "claim": "Dev", "issue": 2669, "summary": "A workflow node was only told the OUTPUTs it declared, while its outgoing edges read OUTPUTs too, so the issue fast line's Triage node never learned to print `state` and runs failed on `Missing OUTPUT state`. stepBody now hands the declared ports plus the outputs the outgoing edges read, and the handoff spells the values an edge compares against. missingVerdicts and the fail path are unchanged.", "files": ["plugins/workflow/src/graph.js", "plugins/workflow/src/service.js", "plugins/workflow/index.js", "plugins/workflow/test/step-body.test.js", "plugins/workflow/test/graph.test.js", "docs/subsystems/workflow.md", "changelog.d/2669-edge-outputs.fixed.md"], "checks": { "ran": "plugins/workflow: node --test test/*.test.js and the four-file brief set; changelog.mjs check", "result": "green", "at": "6c9eca56cca0cf08571a368af6c7ee74db08e4ad" }, "next": "none — ready for review" }