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
CLI hangs indefinitely on session resume when ssh got disconnected during a long running command #12515
Title: Codex hang when SSH session closes during active tool call
Date: 2026-02-22
Environment:
Codex CLI: 0.104.0
OS: Linux aarch64 (Debian bookworm, kernel 6.12.47+rpt-rpi-v8)
Shell: bash 5.2.15
Workspace: /mnt/device1/firmware
Observed behavior:
A long-running tool command was dispatched, entered running state, then the SSH session
closed shortly after. Likely, the rollout never received normal completion for that command and the agent remained in a waiting/stalled state until resumed/interrupted, which leads to a state that, when the session is resumed, it will stay in 'Working' indefinitely. See more details in the protocol
Feb 22 18:20:33 local: pam_unix(sshd:session): session closed for user pi
captured in /tmp/openai-hang-debug-20260222-2148/02b-ssh-filtered-with-close.txt
Related non-graceful task warning:
codex-tui.log contains: “task ... didn't complete gracefully after 100ms”
extracted in /tmp/openai-hang-debug-20260222-2148/03-codex-warnings.txt
Hypothesis:
Race condition between tool/process execution state and transport/session teardown (SSH/
PTY), leaving the engine waiting for a completion event that never arrives.
Activity