Mid-session prompt suggestions populate input buffer and submit on Enter
Status Fixed / completed
Maintainer reply None cached
Activity 5 comments · opened May 4, 2026 · closed May 7, 2026
Bug: Mid-session prompt suggestions populate input buffer and submit on Enter
Version
Claude Code v2.1.126, Windows 11 Pro, PowerShell, Claude Pro (Opus 4.6)
Summary
During an active session, context-aware text appears in the input prompt that the user did not type. Unlike the startup placeholder hints (e.g. try "create a util logging.py that..."), these mid-session suggestions populate the actual input buffer and can be submitted by pressing Enter.
Steps to reproduce
- Start a Claude Code session and work on a multi-step task (editing files, pushing to git, etc.)
- After Claude completes a response, observe the input prompt
- Context-aware suggestion text appears in the prompt without any user input
- Pressing Enter submits the suggestion as if the user typed it
Observed behaviour
Startup hint (harmless)
- Grey placeholder text like
try "create a util logging.py that..."appears on fresh launch - Pressing Enter does not submit this text — it behaves as placeholder/ghost text
- Disappears when user starts typing
Mid-session suggestions (dangerous)
- After completing a git push, the prompt populated with: "check the deploy"
- After editing a landing page layout, the prompt populated with: "can we cut the topic lanes, they're not adding much"
- These are context-aware — they reference the current task, not generic suggestions
- Pressing Enter does submit this text as a real user message
- The user did not type any of this text
Expected behaviour
The input prompt should never contain submittable text that the user did not type. Suggestions should either:
- Be clearly distinguished as non-submittable placeholder text (like the startup hints), or
- Not appear at all without explicit opt-in
Risk
This is a safety issue. An unsolicited, context-aware suggestion that submits on Enter could:
- Trigger unwanted file edits or deletions
- Execute git operations (push, reset, etc.)
- Run destructive shell commands
- Make changes the user didn't intend or review
The user may not notice the prompt has been pre-filled, especially during fast-paced work sessions.
Screenshots
Available on request — two separate instances captured during a single session.
Environment
- Claude Code v2.1.126
- Windows 11 Pro 10.0.26200
- PowerShell
- Opus 4.6 with high effort
- Claude Pro subscription
- Custom launcher (CLAW) — confirmed not the source, it does not interact with stdin
- PSReadLine PredictionSource: blank/none — confirmed not the source
5 Comments
Found 3 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
Adding context from the linked duplicates — this is a recurring issue that keeps getting auto-closed without resolution.
#25787 documents the core UX problem thoroughly: Enter simultaneously accepts and executes suggestions, violating CLI conventions (Fish, Zsh, Bash, GitHub Copilot CLI all require Tab/Arrow acceptance before Enter executes). That issue itself references two earlier reports (#14500, #16166) that were also auto-closed.
#20439 demonstrates real-world damage: an autocomplete suggestion of "merge it" was accidentally submitted when the user pasted a screenshot, causing a PR to be merged without user intent.
My report adds a new dimension — context-aware suggestions appearing mid-session that populate the actual input buffer. These aren't generic placeholder hints. After a git push, "check the deploy" appeared. After editing a landing page, "can we cut the topic lanes, they're not adding much" appeared. Both were submittable on Enter.
This has been reported independently by multiple users across macOS, Linux, and now Windows since at least January 2026. The proposed fix in #25787 (decouple acceptance from execution via a tab_accepts config option) is clean and non-breaking. Please don't let the auto-close bot bury this again.
Still reproduces on Claude Code v2.1.141 (latest as of 2026-05-13).
Environment
plugins, no env overrides that touch the input box.
Same symptoms as the original report: a startup placeholder is harmless, but mid-session the input gets pre-populated
with context-aware text (referencing the just-completed tool calls / file edits) that does submit on Enter. Nothing
local can be removed to disable it — there's no setting that controls it.
Bumping because this is still a safety issue: with skipAutoPermissionPrompt on, an accidental Enter on an injected
"push the branch" or "reset to main" runs without a confirmation gate.
I am also experiencing this. One thing that I haven't seen anyone mention is how it PERSISTS when you start typing and completely mangled your text.
It doesn't submit mangled text, but it sure does make it hard to read when you're typing!
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.