Skip to content

Conversation

yayami3
Copy link
Contributor

@yayami3 yayami3 commented Oct 12, 2025

Description

Fixes #3155 - Tool descriptions (e.g., file paths) were not displayed in permission prompts.

Problem

When Q requests permission to use a tool, the tool description was not visible to users:

Before:

🛠️  Using tool: fs_read
 ⋮ 
 ● 
Allow this action? [y/n/t]:

After:

🛠️  Using tool: fs_read
 ⋮ 
 ● Reading file: /tmp/foo.txt, all lines
Allow this action? [y/n/t]:

Root Cause

The queue! macro buffers output and requires an explicit flush() to display content. The print_tool_description() method was missing a flush() call after queue_description().

Changes

  • Added self.stdout.flush()? in print_tool_description() method
  • File: crates/chat-cli/src/cli/chat/mod.rs
  • Lines: +2

Checklist

  • Code follows the project's style guidelines
  • Changes have been tested locally
  • No breaking changes introduced

Fixes issue aws#3155 where tool descriptions (e.g., file paths) were not
displayed in permission prompts. The queue! macro buffers output, so
an explicit flush() is needed after queue_description to ensure the
buffered content is displayed before the permission prompt.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: fs_read no longer shows the file name

1 participant