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
AskUserQuestion multi-question wizard resets to question 1 after switching sessions #5813
In the desktop app, when the agent asks a multi-question AskUserQuestion, answering question 1 and then switching to another session and back resets the wizard to question 1. The answer already given is lost.
Steps to reproduce
Start a task where the agent calls AskUserQuestion with more than one question.
Answer question 1 and advance to question 2 (2 / 2 is shown).
Switch to another session.
Switch back.
Expected
The wizard resumes at question 2 with the question-1 answer still selected.
Actual
The wizard restarts at question 1 (1 / 2); the previously selected answer is gone.
Root cause
UserQuestionPrompt (packages/ui/src/user-question-prompt.tsx) keeps the wizard progress — current question index, committed per-question drafts, and the in-flight free-form text — in component-local useState. Switching sessions unmounts the prompt, so returning mounts a fresh component whose state initializes back to question 0 with empty drafts.
Plan: persist AskUserQuestion wizard progress keyed by requestId in user-question-prompt-state.ts so remounting after a session switch restores in-progress answers. Clear the store on successful submit. Branch: fix/5813-user-question-wizard-persist
Activity
garvit-arora commentedon Sep 29, 2026
take
garvit-arora commentedon Sep 29, 2026
Plan: persist AskUserQuestion wizard progress keyed by requestId in user-question-prompt-state.ts so remounting after a session switch restores in-progress answers. Clear the store on successful submit. Branch: fix/5813-user-question-wizard-persist
garvit-arora commentedon Sep 29, 2026
Opened PR: #5854
fix(ui): keep AskUserQuestion wizard progress across session switches
fix(ui): persist AskUserQuestion wizard across session switches
fix(ui): persist AskUserQuestion wizard across session switches