aws / aws/amazon-q-developer-cli

bug: Conflict between agent configs - toolSettings and allowedTools

Open
#2,884 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

MacOS

### Expected behaviour

When `fs_write` is not added to the list of `allowedTools`, then having a field for fs_write in "toolSettings" should not assume fs_write is trusted.

- `allowedTools` should take precedence over toolSettings, at least for fs_write. `allowedTools` should be the only source of truth for trust settings.

### Actual behaviour

When `fs_write` in present in `toolSettings` of cli-agent configuration, it assumes fs_write is trusted even when allowedTools does not contain fs_write.

Also, running `/tools` in this case does not show fs_write as trusted, even though it is used as a trusted tool.

### Steps to reproduce

1. Add some toolSettings for fs_write - say `allowedPaths` in a cli-agent configuration
2. Start q chat with the agent loaded.
3. Ask it to make changes to a file in the configured allowedPaths. It will proceed to do so as a trusted tool.
4. Check `/tools`, which shows fs_write as not trusted.

### Environment

```yaml
[q-details]
version = "1.15.0"
hash = "eb8db5c635fc469f3bd94ead16bb4bfb32d7443b"
date = "2025-09-02T17:57:24.662205Z (13d ago)"
variant = "full"

[system-info]
os = "macOS 15.6.1 (24G90)"
chip = "Apple M1 Pro"
total-cores = 10
memory = "32.00 GB"

...
```

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.