Description
When using Gemini CLI via ACP protocol (spawned by Alma app), the run_shell_command tool consistently fails to return results, causing the AI SDK to throw AI_MissingToolResultsError.
Steps to Reproduce
- Run Gemini CLI with ACP flags:
gemini --acp --experimental-acp
- Ask for a shell command execution (e.g., 'run
ls command')
- Observe the error
Expected Behavior
The run_shell_command tool should execute successfully and return results to the ACP client.
Actual Behavior
run_shell_command tool call is initiated but never returns a result
- ACP client receives no tool result
- Error:
AI_MissingToolResultsError: Tool results are missing for tool calls run_shell_command-xxx
Environment
- Gemini CLI version: 0.34.0
- macOS Sonnet
- ACP Client: Alma v0.0.723
- Flags used:
--acp --experimental-acp
Additional Context
This appears to be related to existing issues #14561 and #5382. The issue is that in ACP/non-interactive mode, the run_shell_command tool cannot render user confirmation prompts and fails silently without returning a result to the ACP stream.
Suggested Fix
- Handle ACP/non-interactive mode for
run_shell_command tool
- Either auto-approve commands in ACP mode or return an error result instead of hanging indefinitely
- Ensure tool results are always returned to the ACP stream, even on failure
Description
When using Gemini CLI via ACP protocol (spawned by Alma app), the
run_shell_commandtool consistently fails to return results, causing the AI SDK to throwAI_MissingToolResultsError.Steps to Reproduce
gemini --acp --experimental-acplscommand')Expected Behavior
The
run_shell_commandtool should execute successfully and return results to the ACP client.Actual Behavior
run_shell_commandtool call is initiated but never returns a resultAI_MissingToolResultsError: Tool results are missing for tool calls run_shell_command-xxxEnvironment
--acp --experimental-acpAdditional Context
This appears to be related to existing issues #14561 and #5382. The issue is that in ACP/non-interactive mode, the
run_shell_commandtool cannot render user confirmation prompts and fails silently without returning a result to the ACP stream.Suggested Fix
run_shell_commandtool