aws / aws/amazon-q-developer-cli
The conversation history is too large to compact
- Dominant language
- Rust
- Stars
- 2k
- Forks
- 439
- PR merge metrics
- No merged PRs in 30d
Description
### Checks
- [x] I have searched [github.com/aws/amazon-q-developer-cli/issues](https://github.com/aws/amazon-q-developer-cli/issues?q=) and there are no duplicates of my issue
- [x] I have run `q doctor` in the affected terminal session
- [x] I have run `q restart` and replicated the issue again
### Operating system
macOS 14.6.1 (23G93)
### Expected behaviour
compact should handle large history, that is why we need /compact
### Actual behaviour
q crashes with The conversation history is too large to compact
```
The context window has overflowed, summarizing the history...
Reducing context...
Your conversation is too large to continue.
• Run /usage to analyze your context usage
• Run /clear to reset your conversation state
Unable to compact the conversation history:
0: The conversation history is too large to compact
Location:
crates/chat-cli/src/cli/chat/mod.rs:728
Backtrace omitted. Run with RUST_BACKTRACE=1 environment variable to display it.
Run with RUST_BACKTRACE=full to include source snippets.
> /compact
Reducing context...
>
```
### Steps to reproduce
_No response_
### Environment
```yaml
[q-details]
version = "1.12.3"
hash = "65aa9285fc7ec3716215386a89d3a626500a25a7"
date = "2025-07-03T01:14:12.212107Z (6d ago)"
[system-info]
os = "macOS 14.6.1 (23G93)"
chip = "Apple M2"
total-cores = 8
memory = "24.00 GB"
[environment]
cwd = "/Users/USER/projects/nextutor"
cli-path = "/Users/USER/projects/nextutor"
install-method = "unknown"
[env-vars]
PATH = "/opt/homebrew/opt/postgresql@16/bin:/opt/homebrew/opt/libpq/bin:/Users/USER/.sdkman/candidates/java/current/bin:/Users/USER/.sdkman/candidates/gradle/current/bin:/Users/USER/.nvm/versions/node/v9.11.2/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/Applications/VMware Fusion Tech Preview.app/Contents/Public:/opt/podman/bin:/Users/USER/.local/bin:/Users/USER/Library/Application Support/JetBrains/Toolbox/scripts"
QTERM_SESSION_ID = "6a7325297aab4e38a0fac50d524f3dd8"
Q_SET_PARENT_CHECK = "1"
Q_TERM = "1.12.1"
SHELL = "/bin/zsh"
TERM = "xterm-256color"
__CFBundleIdentifier = "com.apple.Terminal"
```
Contributor guide
Assessment
This issue has not been assessed yet.