🤖 fix: isolate workflow-owned sub-agent outputs#3451
Conversation
Hide workflow-owned sub-agents and their background bash tasks from task_list/default task_await discovery so parent agents only see vetted workflow-run output.\n\nValidation:\n- bun test src/node/services/tools/task_list.test.ts src/node/services/tools/task.bash.test.ts src/node/services/taskService.test.ts\n- make typecheck\n- make lint\n\n---\n\n_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `.19`_\n\n<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=6.19 -->
Reject explicit task_await calls for workflow-owned agent tasks and descendant bash processes so parent agents cannot bypass workflow-run vetting. Persist workflow-ownership metadata with subagent reports so the guard still works after task cleanup/restart.\n\nAlso update task_await's tool contract and generated hook docs to document the omitted-ID workflow-owned exclusion.\n\nValidation:\n- bun test src/node/services/tools/task_await.test.ts src/node/services/tools/task.bash.test.ts src/node/services/tools/task_list.test.ts src/node/services/taskService.test.ts\n- make static-check\n\n---\n\n_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `5.41`_\n\n<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=25.41 -->
|
@codex review Please review this workflow-owned sub-agent output isolation change. |
|
Codex Review: Didn't find any major issues. You're on a roll. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
|
@codex review Re-requesting after the CI timeout fix commit. |
|
Codex Review: Didn't find any major issues. Swish! ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Increase built-in workflow test timeouts after CI hit Bun's 5s default while these tests passed locally just under that boundary.\n\nValidation:\n- bun test src/node/services/workflows/builtInWorkflowDefinitions.test.ts\n- make static-check\n\n---\n\n_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `6.26`_\n\n<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=36.26 -->
58586c2 to
7b5c39a
Compare
|
@codex review Re-requesting after the built-in workflow timeout fix. |
|
Codex Review: Didn't find any major issues. 🚀 ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Summary
Hide workflow-owned sub-agents from parent-facing task discovery and direct awaits so parent agents consume workflow-vetted output through workflow runs instead of raw child reports.
Background
Workflow-launched sub-agents are coordinated by the workflow runner, which owns their reports, retries, structured output validation, and final synthesis. Parent agents should not accidentally discover or await those raw child task outputs through
task_listortask_await.Implementation
task_list, including descendants of workflow-owned tasks.task_idstask_awaitdiscovery.task_awaitcalls for workflow-owned agent task IDs and bash processes in workflow-owned descendant workspaces.task_awaittool contract and generated hook docs to document the workflow-owned exclusion.Validation
bun test src/node/services/tools/task_await.test.ts src/node/services/tools/task.bash.test.ts src/node/services/tools/task_list.test.ts src/node/services/taskService.test.tsbun test src/node/services/workflows/builtInWorkflowDefinitions.test.tsmake static-checkRisks
Medium risk in task/workflow orchestration behavior: this deliberately changes which descendant tasks are visible/awaitable from a parent workspace. Regular sub-agent tasks and workflow run awaits remain supported; workflow-owned child output is intentionally reachable only through workflow run results.
Generated with
mux• Model:openai:gpt-5.5• Thinking:xhigh• Cost:$36.26