Skip to content

Commit ee7a68b

Browse files
authored
fix: flush stdout after queue_description to display tool information (#3156)
Fixes issue #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.
1 parent 1999b5a commit ee7a68b

File tree

1 file changed

+2
-0
lines changed
  • crates/chat-cli/src/cli/chat

1 file changed

+2
-0
lines changed

crates/chat-cli/src/cli/chat/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3269,6 +3269,8 @@ impl ChatSession {
32693269
.await
32703270
.map_err(|e| ChatError::Custom(format!("failed to print tool, `{}`: {}", tool_use.name, e).into()))?;
32713271

3272+
self.stdout.flush()?;
3273+
32723274
Ok(())
32733275
}
32743276

0 commit comments

Comments
 (0)