You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Ctrl+C can leave session locked with stale active writer, preventing resume #43374
Pressing Ctrl+C while using Codex CLI can leave the current session stuck as having an active writer. After restarting Codex and trying to resume the same session, resume fails with an already has an active writer error.
Environment
Codex CLI: 0.153.4
Platform: Linux
Steps to reproduce
Start codex.
Work in a session normally.
Press Ctrl+C while Codex is running/working.
Start Codex again.
Attempt to resume the previous session.
Resume fails because the thread is reported as already having an active writer.
Actual behavior
thread/resume failed during TUI bootstrap: thread/resume failed: thread <thread-id> already has an active writer (code -32600)
The previous Codex process has already exited, but the writer ownership appears to remain stale, so the session cannot be resumed normally.
Expected behavior
Ctrl+C should cleanly release the thread writer/ownership before exiting, or stale writer ownership should be detected and recovered automatically when resuming.
A session should not become unusable simply because the previous Codex process was interrupted with Ctrl+C.
Suggested fix
Either:
gracefully release the active writer on SIGINT, or
detect that the previous writer no longer exists and reclaim the session on resume.
This has happened repeatedly and is easy to trigger accidentally in a terminal.
Activity