Mirror Codex native subagents into task registry#79512
Conversation
|
Codex review: needs maintainer review before merge. Summary Reproducibility: not applicable. as an end-user bug report; this is a feature PR. The behavior is source-reviewable in the mirror and alias code, and the PR body includes terminal proof from a real gateway producing a Real behavior proof Next step before merge Security Review detailsBest possible solution: Land a maintainer-approved version that keeps task mutation private to bundled Codex, preserves the no- Do we have a high-confidence way to reproduce the issue? Not applicable as an end-user bug report; this is a feature PR. The behavior is source-reviewable in the mirror and alias code, and the PR body includes terminal proof from a real gateway producing a Is this the best way to solve the issue? Mostly yes, subject to maintainer approval. The branch keeps task mutation helpers out of the public SDK and scopes the private alias to bundled Codex, which is narrower than a public SDK seam unless external plugins need this capability. What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against 7ee8e0b64188. |
f746f2c to
cf32569
Compare
e09264d to
0bbb950
Compare
539c639 to
0bbb950
Compare
8614d71 to
82f960d
Compare
82f960d to
75bc96a
Compare
|
Merged via squash.
Thanks @mbelinky! |
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash # Conflicts: # extensions/codex/src/app-server/event-projector.ts
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash # Conflicts: # extensions/codex/src/app-server/event-projector.ts
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Merged via squash. Prepared head SHA: 75bc96a Co-authored-by: mbelinky <mbelinky@users.noreply.github.com> Co-authored-by: marianobelinky <63976030+marianobelinky@users.noreply.github.com> Reviewed-by: @pashpashpash
Summary
subagent/codex-nativetasks.thread/started/thread/status/changedevents and livecollabAgentToolCallstate from nativespawnAgent/waititems.runId/sourceId(codex-thread:<threadId>) and deliberately leavechildSessionKeyunset so OpenClaw task maintenance/cancellation does not treat native Codex threads as OpenClaw-managed child sessions.agent-harness-runtimeSDK surface by routing the bundled Codex plugin through a private local-onlyopenclaw/plugin-sdk/codex-native-task-runtimesubpath, include that private helper in the build output, and allow that specific non-QA private helper only for bundled Codex alias resolution.Current-head proof
Current PR head:
75bc96ad74ba6c082e933aae0f372fd1cb76f19c.origin/mainat validation time:d0edacad5be774d6f26963148a34a7f05ac71cf8.pnpm buildpassed;pnpm checkpassed.pnpm testdid not pass on local maintainer hardware. The failures were in files outside this PR's diff, includingsrc/agents/*,extensions/telegram/*,extensions/nvidia/*,extensions/openrouter/*, andextensions/mattermost/*. The Codex app-server failures emitted in the broad run passed when rerun directly, so this is being treated as broad-suite/baseline noise rather than a PR blocker.pnpm --config.verify-deps-before-run=false test src/plugins/sdk-alias.test.ts src/plugins/contracts/plugin-sdk-root-alias.test.ts extensions/codex/src/app-server/native-subagent-task-mirror.test.ts extensions/codex/src/app-server/event-projector.test.ts extensions/codex/src/app-server/run-attempt.test.ts extensions/codex/src/app-server/run-attempt.context-engine.test.ts extensions/codex/src/app-server/auth-profile-runtime-contract.test.ts src/tasks/detached-task-runtime.test.ts- passed, 232 tests.pnpm --config.verify-deps-before-run=false exec oxfmt --check --threads=1 ...,node scripts/check-plugin-sdk-subpath-exports.mjs,node scripts/check-extension-plugin-sdk-boundary.mjs src-outside-plugin-sdk,node scripts/check-extension-plugin-sdk-boundary.mjs plugin-sdk-internal,pnpm --config.verify-deps-before-run=false plugin-sdk:api:check, andgit diff --check origin/main...HEAD- passed..github/workflows/*, live Docker harness, Testbox, or validation-tooling changes. Tooling stays private to maintainer validation.Real behavior proof
subagent/codex-nativerows instead of only existing in Codex session/transcript surfaces.jpclawhqmain OpenClaw gateway checkout at/srv/openclaw/main. No Testbox/workflow/tooling changes are part of this PR./srv/openclaw/main, ranpnpm build, restarted withsudo systemctl restart openclaw-gateway, checkedsudo openclaw-runtime-status, checked/usr/local/bin/openclaw-main nodes status --json, then inspected Task Registry rows for Codex-native subagent records after a live Codex app-server native subagent run. The final current head only narrows the private helper alias to bundled Codex and refreshes generated SDK baseline hash; the Task Registry mirror behavior covered by this gateway proof is unchanged from that live run.runtime=subagent,taskKind=codex-native, and terminalsucceededstatus for native subagent spawns.pnpm testremains red in unrelated/baseline areas. A fresh final-head Testbox packaging/import proof was queued for about ten minutes and stopped because capacity did not clear; no active Testboxes remain.Maintainer flow checks
release/2026.5.10.main.