feat(codex): add mode controls, live status, and bound collaboration mode (PR 1/3)#2
Closed
SYU8384 wants to merge 9027 commits into
Closed
feat(codex): add mode controls, live status, and bound collaboration mode (PR 1/3)#2SYU8384 wants to merge 9027 commits into
SYU8384 wants to merge 9027 commits into
Conversation
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.
Summary
Draft of the Codex channel-native session controls sub-PR 1.
This branch cherry-picks the 43 Codex codex-plan-controls commits from
origin/feat/codex-plan-controls(the PR 88446 history) ontomain,plus 2 fixup commits for the two pre-existing PR bugs the cherry-pick
exposed. One Codex commit (
b881e41 chore: drop local repro and proof-state artifacts) is dropped — it only deletes local scratchfiles that don't belong on a public branch.
The
a4fc8faand34b681ecommits are applied as their originalcherry-picks (the demo-widget-removal half of
34b681ewas a no-opbecause the widget files no longer exist on
main).What's in this branch
/codex plan|think|live|permissions|status) and/codex modelsetter with bound conversation-target preservation.or env surfaces.
persistence in
CodexAppServerThreadBindingand the Codex runtimeoptions shape.
profile fall-through.
Fixups applied on top of the cherry-pick
ea3c4d9a8b fix(codex): restore closing paren in dispatch-from-config before_dispatch hook— the original15eda36commit removed aclosing paren in
src/auto-reply/reply/dispatch-from-config.ts:2112when it added the
before_dispatcharrow-function body. This breaksthe
traceReplyPhasecall. Verified viagit show 15eda36fa8:src/auto-reply/reply/dispatch-from-config.tsthat the bug is in the original PR.
bf868c7e32 fix(codex): guard channel in before_dispatch freeform answer handler— the original15eda36commit addedchannel: event.channel ?? ctx.channelIdinextensions/codex/index.ts:186where the helper requires a non-nullstring. The current branch has an explicit
if (!channel) return;guard; this fixup restores it. Also reformats the test assertion
block to match.
The branch also took HEAD side for
session-binding.ts,thread-lifecycle.ts,compact.ts,side-question.ts,conversation-control.ts,conversation-binding.ts,command-handlers.ts,run-attempt.ts,app-server-policy.ts,approval-bridge.ts,config.ts,harness.ts,cli-runner.ts,attempt.ts,run-state.ts,acp-runtime-backend.ts,hook-agent-context.ts,hook-types.ts, andget-reply.tstosatisfy missing exports and hook-context type references that the
PR 2 commits would have provided. These HEAD-side takes lose some
of the original PR's specific changes to those files; the user can
rebase the PR 2 commits on top to restore the full PR 2 surface.
Verification
pnpm tsgo:extensions— 0 errors.pnpm build— clean.node scripts/run-vitest.mjs(9 codex test files) — 16 failuresremain in
extensions/codex/index.test.ts(Discord callbacktests),
extensions/codex/src/app-server/config.test.ts(approvalpolicy tests), and
extensions/codex/src/app-server/thread-lifecycle.test.ts(model-refsplitting tests). These pass on
mainand on the current branchfeat/stack-rebased-20260604; the failures are caused by thecherry-pick producing a state that doesn't match either of those
baselines exactly. Tracked as follow-up fixes.
Plan / upstream notes
Per the upstream plan in
codex-channel-native-session-controls-plan.mdandcodex-plan-controls-pr-split-plan.md:codex-rs/protocol/src/protocol.rs:3675-3728(ReviewDecision),codex-rs/protocol/src/approvals.rs:218-265(
ExecApprovalRequestEvent),codex-rs/app-server-protocol/src/protocol/common.rs:1336,1343,1361(v2 RPC method strings).
feat/codex-plan-controls-chat)and PR 3 (
feat/codex-plan-controls-approvals, net-new code) aredrafted in sibling worktrees.
Not ready for review
resolved before merge.
PR 2 commits to keep the full chat-control surface.
marking ready for review.
openclaw#88446