Return WorkflowStartResult from Workflow.start()#34
Closed
czpython wants to merge 3 commits into
Closed
Conversation
start() hands back the run to follow plus is_duplicate, sourced only from the DBOSQueueDeduplicatedError catch; the terminal-holder recursion path propagates the recursive call's result. Dispatch callers keep their string contracts via .run_id, the dedup tests pin both flags, and the author guide carries the one-line migration note. Touched files also brought to the house checklist: bare guard returns and positive input branching.
The surface test pins the new export, and every test double standing in for start() hands back the model — including the two whose callers discard the return, so the stubs stay shape-faithful.
Owner
Author
|
Closing: cutting The removal landed on the two stacked PRs: #36 ( |
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.
T2 of the MCP arc (spec: tmp/mcp-arc-tickets.md).
start()now returnsWorkflowStartResult(run_id, is_duplicate)so dispatch surfaces can tell a fresh enqueue from the subject's already-live run — the fact the agent-facing dispatch route (T3) needs to report duplicate-as-success.is_duplicateis sourced only from theDBOSQueueDeduplicatedErrorcatch; the terminal-holder recursion path propagates the recursive call's result; no preflight reads, no compat shim. Dispatch callers keep their string contracts via.run_id.Test evidence: dedup tests now pin both flags (
test_duplicate_start_returns_the_live_run,test_duplicate_start_shares_the_run_across_accounts); ~30 assertion sites updated across the four durable test files; ruff + format clean, pyright error multiset identical to main's baseline; backend suite runs in CI.Merge gate: druks-discovery companion prepared locally on
eng/workflow-start-result-companion@ f33f7de (not pushed) — coordinate before merging this.