aws / aws/amazon-q-developer-cli

Amazon Q prematurely ends response when about to show implementation

Open
#1,362 0 comments 0 reactions 0 assignees View on GitHub
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

Linux 5.10.235-208.919.amzn2int.x86_64 - Amazon Linux 2

### Expected behaviour

Showing the action or implementation that is described by Amazon Q.

### Actual behaviour

Sometimes when Amazon Q is about to show a code implementation or use a tool, the response will end prematurely with something like: "Let's try to delete the stack again with the correct region:" and then return control to the user without actually doing the thing. In this case, I suspect it was going to make an aws call. I've also seen this behavior when I would expect the response to include a diff of code or something along those lines.

```
[chat-transcript]
> I'm trying to delete an AWS cloudformation stack but I keep getting errors. Can you help guide me through it? use aws cli profile '' for aws calls. The stack I'm trying to delete is in the region us-west-1

I'll help you delete the CloudFormation stack using the AWS CLI with the specified profile. Let's first check the status of the stack to understand why it might be failing to delete.
[Tool uses: use_aws]

It seems the stack "" doesn't exist in the us-west-1 region with the profile. Let's verify the available stacks to make sure we have the correct name:
[Tool uses: use_aws]

There are no stacks listed in the us-west-1 region with the profile. Let's check if the stack might exist in a different region:
[Tool uses: use_aws]

I found the stack! It looks like the stack "" exists in the us-east-1 region (not us-west-1), and it's currently in a DELETE_FAILED state. According to the error message, the deletion failed because of two resources that couldn't be deleted:

\```
"StackStatus": "DELETE_FAILED",
"StackStatusReason": "The following resource(s) failed to delete: [, ]. "
\```

These appear to be KMS keys that are likely still in use or have a deletion policy that prevents automatic deletion.

Let's try to delete the stack again with the correct region:
[Tool uses: none]

> /issue

I'd be happy to help you report an issue or make a feature request. You can use the `report_issue` tool to submit your feedback directly to the GitHub repository.

To proceed, I'll need some details about what you'd like to report:

1. What's the title or brief description of your issue/feature request?
2. What's the actual behavior you're experiencing (for issues)?
3. What's the expected behavior you'd like to see?
4. Are there any specific steps to reproduce the issue?

Once you provide these details, I can help you submit the report through the appropriate channel.
[Tool uses: none]

> Title: Amazon Q prematurely ends response when about to show implementation.>
>
Behavior: Sometimes when Amazon Q is about to show a code implementation or use a tool, the response will end prematurely with something like: "Let's try to delete the stack again with the correct region:" and then return control to the user without actually doing the thing. In this case, I suspect it was going to make an aws call. I've also seen this behavior when I would expect the response to include a diff of code or something along those lines.>
>
Expected behavior: Showing the action or implementation that is described by Amazon Q.>
>
Steps to reproduce: I'm not sure on these since many of the Amazon Q response seem to be non-deterministic. You need to ask questions that will require Amazon Q to use a tool as that seems to be correlated.

I'll help you report this issue about Amazon Q prematurely ending responses when about to show implementations or use tools.
[Tool uses: report_issue]
```

### Steps to reproduce

I'm not sure on these since many of the Amazon Q response seem to be non-deterministic. You need to ask questions that will require Amazon Q to use a tool as that seems to be correlated

### Environment

```yaml

[q-details]
version = "1.8.0"
hash = "da59663e5955cc8bc93064fe89053977ff513311"
date = "2025-04-24T16:36:17.050128Z (1d ago)"
variant = "minimal"

[system-info]
chip = "AMD EPYC 7R13 Processor"
total-cores = 4
memory = "15.26 GB"

[system-info.os.linux]
kernel_version = "5.10.235-208.919.amzn2int.x86_64"
id = "amzn"
name = "Amazon Linux"
pretty_name = "Amazon Linux 2"
version_id = "2"
version = "2"
variant = "internal"

[environment]
cwd = "/local/home/USER"
cli-path = "/local/home/USER"
os = "Linux"
shell-path = "/local/home/USER/.toolbox/tools/toolbox/1.1.1762.0/toolbox-exec"
shell-version = "5.8"
install-method = "toolbox"
in-ssh = true

[env-vars]
PATH = "/home/USER/.toolbox/bin:/home/USER/.toolbox/bin:/home/USER/go/bin:/usr/local/go/bin:/home/USER/.cargo/bin:/snap/bin:/home/USER/bin:/home/USER/.local/bin:/home/USER/.local/share/mise/installs/node/18.18.2/bin:/home/USER/.local/share/mise/installs/python/3.13.2/bin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/home/USER/.cargo/bin:/usr/local/bin:/usr/bin:/home/USER/bin:/usr/local/sbin:/usr/sbin:/home/USER/.local/bin:/home/USER/.local/share/JetBrains/Toolbox/scripts:/home/USER/bin:/home/USER/.local/share/JetBrains/Toolbox/scripts:/home/USER/bin:/home/USER/bin:/home/USER/.local/share/JetBrains/Toolbox/scripts"
QTERM_SESSION_ID = "d911fa0dd736431f849d6bcfd0422487"
Q_PARENT = "/tmp/q-parent-bed77a1defed4f4c884f03ab1067e190.socket"
Q_SET_PARENT_CHECK = "1"
Q_TERM = "1.8.0"
Q_USING_ZSH_AUTOSUGGESTIONS = "1"
SHELL = "/bin/zsh"
TERM = "tmux-256color"

[chat-settings]
interactive=true

[chat-trusted_tools]

[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=none
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.