Skip to content

fix(eve): forward delegated subagent stream events - #667

Closed
iroiro147 wants to merge 3 commits into
vercel:mainfrom
iroiro147:fix/666-subagent-stream-forwarding
Closed

fix(eve): forward delegated subagent stream events#667
iroiro147 wants to merge 3 commits into
vercel:mainfrom
iroiro147:fix/666-subagent-stream-forwarding

Conversation

@iroiro147

Copy link
Copy Markdown
Contributor

Summary

Delegated task-mode subagents now forward their child session stream events into the parent session stream as durable subagent.event entries. The child stream still receives its original events, and the final subagent-result notification shape remains unchanged.

Closes #666.

Verification

  • pnpm --filter eve exec vitest run --config vitest.unit.config.ts src/execution/workflow-steps.test.ts src/execution/workflow-entry.test.ts
  • pnpm --filter eve exec vitest run --config vitest.unit.config.ts src/execution/durable-session-migrations/turn-workflow.test.ts src/execution/turn-execution-cursor.test.ts src/execution/subagent-tool.test.ts src/execution/subagent-adapter.test.ts src/protocol/message.test.ts
  • pnpm --filter eve run test:unit
  • pnpm --filter eve run typecheck
  • pnpm exec oxlint packages/eve/src/channel/types.ts packages/eve/src/protocol/message.ts packages/eve/src/execution/dispatch-runtime-actions-step.ts packages/eve/src/execution/durable-session-migrations/turn-workflow.ts packages/eve/src/execution/turn-dispatch.ts packages/eve/src/execution/turn-execution-cursor.ts packages/eve/src/execution/turn-workflow.ts packages/eve/src/execution/workflow-entry.ts packages/eve/src/execution/workflow-runtime.ts packages/eve/src/execution/workflow-steps.ts packages/eve/src/execution/subagent-stream-forwarding.ts packages/eve/src/execution/workflow-entry.test.ts packages/eve/src/execution/workflow-steps.test.ts
  • pnpm guard:invariants

@vercel

vercel Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

@iroiro147 is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

Signed-off-by: iroiro147 <sarthak.singh@juspay.in>
@iroiro147
iroiro147 force-pushed the fix/666-subagent-stream-forwarding branch from 170a598 to 195ca15 Compare July 30, 2026 05:40
@iroiro147

Copy link
Copy Markdown
Contributor Author

Rebased onto latest main. Resolved 5 conflicts:

  • dispatch-runtime-actions-step.ts: merged forwardedSubagentStream into the new try/catch error-handling block
  • turn-execution-cursor.ts: kept both the upstream abortSignal parameter and the PR's mutable stepInput pattern
  • workflow-entry.ts (3 conflicts): re-added deliveryHook, mode, parentWritable, and forwardedSubagentStream to all three runTurn call sites that upstream had simplified
  • workflow-runtime.ts: kept the PR's expanded workflow input with forwardedSubagentStream
  • workflow-steps.ts: kept the PR's writeSessionEvent call with forwarded subagent stream

Resolve adjacent-insertion conflict in workflow-steps.test.ts by keeping
both new tests: 'projects a requested sleep onto the durable step result'
(origin/main) and 'forwards delegated subagent stream events to the parent
stream in child order' (this PR). No semantic overlap.
# Conflicts:
#	packages/eve/src/channel/types.ts
@iroiro147

Copy link
Copy Markdown
Contributor Author

Superseded by #1725 (rebased onto latest main; resolved upstream renames: session-delivery-hook→session-command-inbox, Runtime.run→createSession, stampMessageStreamEvent map, session.continuation.rekey). All 594 execution unit tests + tsc --noEmit green on the v2 branch.

@iroiro147 iroiro147 closed this Aug 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature request: forward task-mode subagent stream events to the parent session's stream

1 participant