aws / aws/amazon-q-developer-cli
ValidationException error preventing Amazon Q responses
- 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.5.0 (23F79)
### Expected behaviour
Amazon Q should respond normally to user queries
### Actual behaviour
Amazon Q CLI throws ValidationException with "Improperly formed request" error when trying to respond
```
[chat-transcript]
> Amazon Q is having trouble responding right now: >
0: unhandled error (ValidationException)>
1: service error>
2: unhandled error (ValidationException)>
3: Error { code: "ValidationException", message: "Improperly formed request.", aws_request_id: "9b453730-e86f-4f42-8df9-adb386a28a97" }>
>
Location:>
crates/chat-cli/src/cli/chat/mod.rs:782>
>
Backtrace omitted. Run with RUST_BACKTRACE=1 environment variable to display it.>
Run with RUST_BACKTRACE=full to include source snippets.
I see you're encountering a ValidationException error with Amazon Q. This appears to be a service-level error that's preventing me from responding properly. Let me help you troubleshoot this issue.
Here are some steps to resolve this:
1. **Check your AWS credentials and configuration:**
[Tool uses: execute_bash]
> t
2. **Check your current AWS region:**
[Tool uses: execute_bash]
3. **Try updating the Q CLI to the latest version:**
[Tool uses: execute_bash]
The ValidationException error typically occurs due to:
- Malformed requests being sent to the service
- Issues with authentication or authorization
- Regional availability problems
- Service-side issues
**Immediate troubleshooting steps:**
1. **Restart the Q CLI session:**
- Type `/quit` to exit the current session
- Start a new session with `q chat`
2. **Check if Amazon Q is available in your region:**
Amazon Q Developer might not be available in all regions. Try setting your region to `us-east-1` or `us-west-2`:
\```bash
aws configure set region us-east-1
\```
3. **Clear any cached credentials:**
\```bash
aws configure list
\```
4. **If the issue persists, you can report it:**
[Tool uses: report_issue]
```
### Steps to reproduce
1. Start q chat session 2. Send any query 3. Receive ValidationException error
### Environment
```yaml
[q-details]
version = "1.12.2"
hash = "b9100eb751546269f095585705a0e7fc3ea55419"
date = "2025-06-30T22:40:01.105251Z (17h ago)"
[system-info]
os = "macOS 14.5.0 (23F79)"
chip = "Apple M1"
total-cores = 8
memory = "16.00 GB"
[environment]
cwd = "/Users/USER/Desktop/code/flutter/order_market_app"
cli-path = "/Users/USER/Desktop/code/flutter/order_market_app"
install-method = "brew"
[env-vars]
PATH = "/opt/homebrew/bin:/Users/USER/.bun/bin:/Users/USER/.rbenv/shims:/Users/USER/.console-ninja/.bin:/Users/USER/.nvm/versions/node/v20.15.0/bin:/opt/homebrew/bin:/Users/USER/.rbenv/shims:/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:/Library/Apple/usr/bin:/Users/USER/Desktop/developments/sdk/flutter/bin/:/opt/homebrew/bin:/Users/USER/.bun/bin:/Users/USER/.rbenv/shims:/Users/USER/.console-ninja/.bin:/Users/USER/.nvm/versions/node/v20.15.0/bin:/Users/USER/Desktop/developments/sdk/flutter/bin:/Users/USER/.pub-cache/bin:/Users/USER/.local/bin:/Users/USER/Desktop/developments/sdk/flutter/bin:/Users/USER/Desktop/developments/sdk/flutter/bin:/Users/USER/.pub-cache/bin"
QTERM_SESSION_ID = "0f55c02e4c1947a99690940acc929285"
Q_SET_PARENT_CHECK = "1"
Q_TERM = "1.12.2"
SHELL = "/bin/zsh"
TERM = "xterm-256color"
__CFBundleIdentifier = "com.microsoft.VSCode"
[chat-settings]
[chat-trusted_tools]
execute_bash=true
[chat-failed_request_ids]
none
[chat-context]
current_profile=default
profiles=
default
global_context=
.amazonq/rules/**/*.md
README.md
AmazonQ.md
profile_context=none
files=
/Users/sihyungpark/Desktop/code/flutter/order_market_app/.amazonq/rules/process.md, 0 tkns
/Users/sihyungpark/Desktop/code/flutter/order_market_app/README.md, 1120 tkns
total context size=1120 tkns
```
Contributor guide
Assessment
This issue has not been assessed yet.