Context compaction auto-submits unfinished user message without Enter

Resolved 💬 3 comments Opened May 5, 2026 by Gary-Armstrong Closed May 5, 2026

Description

During context compaction, an in-progress user message was automatically submitted and executed without the user pressing Enter. The user was mid-message when compaction triggered, and the partial/complete message was sent as if the user had confirmed it.

Steps to Reproduce

  1. Have a long conversation that approaches context limits
  2. Begin typing a message but do not press Enter
  3. Context compaction triggers
  4. Message is submitted automatically without user confirmation

Expected Behavior

Context compaction should never submit or execute a pending user message. Any in-progress input should remain in the input buffer, untouched, after compaction completes.

Actual Behavior

The unfinished message was submitted as a command and executed without the user pressing Enter.

Impact

This can cause unintended actions — in this case, infrastructure changes were applied to a live AWS environment based on a message the user had not yet chosen to send. The outcome happened to be acceptable, but this behavior is unsafe in general.

Environment

  • Platform: macOS (darwin 25.3.0)
  • Shell: zsh
  • Model: claude-sonnet-4-6

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗