Gemini CLI stuck on Running? Check the shell result.
The UI status alone cannot show whether a child command is active, waiting for input, or already finished. Capture the exact command and terminal result before retrying it.
What the failure looks like.
The CLI shows Running indefinitely even though the command appears complete. This is especially confusing on Windows or with interactive shell behavior.
Why it happens.
The agent and shell can disagree about command completion when an interactive process does not emit the boundary the CLI expects.
Fix it without losing the task.
What the next AI should receive.
Exact command, terminal and shell mode, working directory, last output or exit code, child-process state, files changed, and whether the command was interactive.
Check before restarting
Check whether the child process is still running and capture its command, shell type, output, and exit status if available. Do not assume the visible terminal finished just because output stopped.
Boundary of the evidence
Issue #24707 is an open user report without a product version; its five-minute behavior and workarounds are not a universal Gemini CLI fix.
Diagnostic checkpoint
Do not replay an ambiguous command until its child process and completion result are known.
How ShardStitch helps.
ShardStitch can carry the current diff and the exact command state into a clean Gemini CLI session or another target. It cannot determine whether a blocked shell process exited; verify that in the terminal.
Source trail.
Specific report, checked September 24, 2026: Gemini CLI issue #24707 was opened April 5, 2026 and remains open with stale/possible-duplicate labels; no product version is listed. It reports run_shell_command opening a PTY for an interactive or slow command, leaving the agent blocked until its five-minute timeout. The reporter's workaround is to request non-interactive commands, use native search tools instead of shell searches where possible, or send < /dev/null for Unix commands. The proposed setting/shorter timeout is a request, not a shipped fix. Browse the project issue tracker.
FAQ.
Does the Running label prove the command is still executing?
No. Confirm the child process state or obtain an exit result. A UI label alone cannot distinguish a live command from a missed completion event.
Is the workaround in issue #24707 a Gemini CLI fix?
No. The linked issue records a reporter's suggestions and a specific environment, not a confirmed product fix. Test a matching non-interactive command in your own setup.
Scope note: Evidence boundary: the linked issue is one report about run_shell_command and a PTY timeout. The described workarounds are reporter suggestions, not a confirmed shipped fix.