Uh oh!
There was an error while loading. Please reload this page.
feat(automation): nested durable pause — subflow chains (linked runs) - #1693
Merged
Conversation
A pausing node (approval/screen/wait) inside a subflow previously failed the parent run and stranded the child's already-persisted continuation as an orphan. Subflow pauses now suspend the whole chain as linked runs: - subflow node: child pauses → suspend the PARENT at the node with correlation 'subflow:<childRunId>', surfacing the child's screen; parent linkage ($parentRunId/$parentNodeId/$parentOutputVariable) rides on the child's persisted context — no sys_automation_run schema change - resume() boundary (no traverseNext/executeNode changes): - down-delegation: resuming a run paused at a subflow forwards the signal to the suspended child; multi-screen children keep the parent run id stable and refresh its surfaced screen - up-bubble: a completed run carrying $parentRunId auto-resumes its parent with the child output mapped exactly like the synchronous path - failure propagation: a child failing terminally after the pause fails every waiting ancestor (bounded walk) instead of stranding them - both directions compose recursively (multi-level nesting), survive process restarts via the durable store, and reuse the existing resume idempotency guards Tests: +7 covering parent-suspend linking, direct-child bubble, parent delegation with screens, multi-screen wizard, two-level nesting, cold-boot restart, and post-pause failure propagation (172 total green). ADR-0019 addendum documents the model and v1 boundaries. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Uh oh!
There was an error while loading. Please reload this page.
os-zhuang added a commit
that referenced
this pull request
Jun 10, 2026
Adds the worked example for nested durable pause (linked runs, #1693): - showcase_closure_signoff: reusable approval subflow (manager sign-off, approve/reject branches recorded into its `decision` output) - showcase_project_closure: on project completion, invokes the sign-off subflow — the child suspends on its approval node, suspending the parent at the subflow node too; the decision bubbles back up and the owner is notified with the outcome Also gates showcase_budget_approval on the budget actually CHANGING (`budget != previous.budget`) — it previously fired on every update of a large-budget project, colliding with any other approval flow on the same record (approvals dedupe pending requests per record), which broke the new example and was wrong on its own terms. Verified live in the browser: complete a project → parent run paused at `signoff` (correlation subflow:<child>) + child paused at `ask_signoff` → approve via /api/v1/approvals → child completes down the approve edge and bubbles: parent resumes, notify_owner runs, both runs completed; the Studio Runs panel shows the same run transitioning paused → completed. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
xuyushun441-sys pushed a commit
that referenced
this pull request
Jun 13, 2026
feat(app-shell): ADR-0048 (A) — package-id app routing (resolution layer) (#1693) objectui@e8ad3ba03c8d804bee32c18c4f1a1c3530ad46a3
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 freeto 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.
Summary
Closes the last known engine capability gap from the flow-engine review: a pausing node (approval / screen / wait) inside a
subflowpreviously failed the parent run and stranded the child's already-persisted continuation as an orphan.Subflow pauses now suspend the whole chain as linked runs (the inter-flow half of the long-term execution-state architecture — cf. Step Functions nested executions / Temporal child workflows; the intra-flow token-tree is a separate future ADR):
correlation: 'subflow:<childRunId>', surfacing the child's screen. Linkage ($parentRunId/$parentNodeId/$parentOutputVariable) rides on the child's persisted context — nosys_automation_runschema change. Descriptor now publishessupportsPause: true.traverseNext/executeNodechanges, per the ADR-0031 multi-agent discipline):getSuspendedScreenstays refresh-safe)$parentRunIdauto-resumes its parent with the child output mapped exactly like the synchronous path (${nodeId}.output+ bareoutputVariable)timeoutMsdoes not span suspension; crash-between-bubble compensable via manual resume).Test plan
tsupbuild + DTS clean (the 2 pre-existing tsc test-file errors reproduce on main untouched)🤖 Generated with Claude Code