AskUserQuestion auto-resolves to the recommended option in `--remote-control` sessions (v2.1.209, `askUserQuestionTimeout` unset)
Environment
- Claude Code v2.1.209, macOS
- Sessions launched non-interactively:
claude --remote-control <name> --dangerously-skip-permissions(bypassPermissions mode), driven by a human via the remote-control web UI askUserQuestionTimeoutNOT set anywhere (user/project/managed settings) → default"never"
Expected
With askUserQuestionTimeout unset (default "never"), an AskUserQuestion should wait indefinitely for an explicit user selection. No answer should be returned to the model without the user actually choosing one.
ActualAskUserQuestion intermittently resolves on its own, returning the recommended option as the answer in the transcript, with no user selection. The user confirms they did not pick it. The model then proceeds as though the user chose the recommended option. Appears associated with the session/connection idling before the user answers.
Repro (best-effort)
- Launch a session:
claude --remote-control <name> --dangerously-skip-permissions(noaskUserQuestionTimeoutset). - Have the model call
AskUserQuestionwith a question whose options include a recommended one. - Leave it unanswered while the session / remote connection sits idle for several minutes.
- Observe the question resolve to the recommended option in-transcript, with no user selection recorded.
Impact
Silently fabricates a user decision: the agent acts on a "choice" the user never made. High-severity for any flow that gates on explicit user confirmation.
Possibly related
- #70648 (remote/cloud
AskUserQuestionre-delivery after idle; answers race a stale connection) - #70294 (interactive prompts not surfaced to remote channels; can appear to hang)
Notes / questions
- The prior auto-select-recommended behavior (#73772) was fixed in v2.1.200, but was auto-mode-specific; this reproduces in bypassPermissions mode on v2.1.209 with the timeout unset — so it does not appear to be that same path. Is there a remaining code path (idle handling in
--remote-control, connection-drop/stale-context recovery) that can resolve anAskUserQuestionto a default/recommended option without a user selection?
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗