Skip to content

fix: pin Codex compact-kill waiter rejection - #551

Open
ladydd wants to merge 2 commits into
LodyAI:mainfrom
ladydd:fix/pin-codex-compact-kill-waiters
Open

fix: pin Codex compact-kill waiter rejection#551
ladydd wants to merge 2 commits into
LodyAI:mainfrom
ladydd:fix/pin-codex-compact-kill-waiters

Conversation

@ladydd

@ladydd ladydd commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Related issue

Closes #550

Depends on LodyAI/acp-extension-codex#38. Review this host PR, then merge the adapter first and this pin second. Do not ship a desktop release until that adapter merge exists.

Problem / pressure

/compact waits on a thread/compacted notification. Turn waiters already reject when the Codex process exits; compaction waiters were resolve-only. If app-server dies after thread/compact/start, the ACP prompt never finishes. Host Stop does not clear it. The next prompt is already active. Healthy compact still works. Mid-turn process death already returns -32603. This is the compact waiter hole, not the fork hang (#543 / #544) and not adapter #30 (stop during compact).

Summary

Pin acp-extension-codex to 35ca9a1 (adapter #38, based on already-merged #37 / e472d56) so close/dispose rejects compaction waiters. Core stays on the 0.1.2 pin from #544. No other submodule moves.

Visual explanation

sequenceDiagram
  participant Host
  participant Adapter
  participant Codex
  Host->>Adapter: prompt /compact
  Adapter->>Codex: thread/compact/start
  Codex-->>Adapter: start ok
  Note over Codex: process exits
  Note over Adapter: before: wait forever for thread/compacted
  Host->>Adapter: session/prompt
  Adapter-->>Host: already active
  Note over Adapter: after: close rejects waiter, prompt returns -32603
Loading

Before / after

Before After
/compact + process death stays compacting; Stop then already active Prompt returns -32603; next prompt is not already active
Healthy /compact Unchanged
Main pins Codex e472d56 (#37) Codex 35ca9a1 (#38 on top of #37)

Test plan

  • Adapter unit: vitest run src/__tests__/CodexAppServerClient.test.ts --no-file-parallelism --retry=0 — 7 passed, including close while start is still in flight.
  • Independent adapter check (Codex 0.153.4, synthetic model, rebuilt bundle of this patch): compact-kill returned -32603 in 10ms with no already active; restart + loadSession then history, a normal prompt, and another compact all completed. Lifecycle 8/8 included real vscode-jsonrpc close while start was pending. Related adapter regression 130 passed; the known /review slash-command timeout is a pre-existing baseline skip.
  • Host change is the gitlink plus Agent Notes. pnpm run docs check reported no errors on the new note pair; the command still fails on pre-existing broken links in unrelated notes/specs. Full pnpm check was not re-run on this pin-only host worktree.
  • Not claimed: in-window Electron compact-kill on this host pin. Acceptance was adapter protocol plus host -32603 classification.

Context handoff

Instructions for reviewing agents

Authoring context

Pin acp-extension-codex to 35ca9a1 (LodyAI/acp-extension-codex#38) so
compaction waiters reject when the Codex process exits. Core stays on
the 0.1.2 pin from LodyAI#544.

Depends on adapter LodyAI#38. Do not ship a desktop release until that merge.

Closes LodyAI#550

Model: grok-4.6
Agent Note for pinning acp-extension-codex 35ca9a1 (adapter LodyAI#38) so
/compact does not hang when the process exits after start.

Model: grok-4.6
@ladydd
ladydd marked this pull request as ready for review September 9, 2026 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Codex /compact stays active after app-server exits

1 participant