Merge 971d350e53 into 4ea31c1bc9
This commit is contained in:
commit
36095a9e6e
|
|
@ -7763,15 +7763,20 @@ impl LiveCli {
|
||||||
match result {
|
match result {
|
||||||
Ok(summary) => {
|
Ok(summary) => {
|
||||||
self.replace_runtime(runtime)?;
|
self.replace_runtime(runtime)?;
|
||||||
|
// The assistant response was already streamed to the terminal live
|
||||||
|
// during the turn (emit_output = true), so reprinting the full text
|
||||||
|
// here would duplicate the entire message. When text was streamed,
|
||||||
|
// emit a newline first so `spinner.finish`'s line-clear lands on a
|
||||||
|
// fresh line instead of erasing the last streamed line.
|
||||||
|
let final_text = final_assistant_text(&summary);
|
||||||
|
if !final_text.is_empty() {
|
||||||
|
println!();
|
||||||
|
}
|
||||||
spinner.finish(
|
spinner.finish(
|
||||||
"✨ Done",
|
"✨ Done",
|
||||||
TerminalRenderer::new().color_theme(),
|
TerminalRenderer::new().color_theme(),
|
||||||
&mut stdout,
|
&mut stdout,
|
||||||
)?;
|
)?;
|
||||||
let final_text = final_assistant_text(&summary);
|
|
||||||
if !final_text.is_empty() {
|
|
||||||
println!("{final_text}");
|
|
||||||
}
|
|
||||||
println!();
|
println!();
|
||||||
if let Some(event) = summary.auto_compaction {
|
if let Some(event) = summary.auto_compaction {
|
||||||
println!(
|
println!(
|
||||||
|
|
@ -7903,6 +7908,9 @@ impl LiveCli {
|
||||||
match new_runtime.run_turn(input, Some(&mut rp)) {
|
match new_runtime.run_turn(input, Some(&mut rp)) {
|
||||||
Ok(summary) => {
|
Ok(summary) => {
|
||||||
self.replace_runtime(new_runtime)?;
|
self.replace_runtime(new_runtime)?;
|
||||||
|
if !final_assistant_text(&summary).is_empty() {
|
||||||
|
println!();
|
||||||
|
}
|
||||||
spinner.finish(
|
spinner.finish(
|
||||||
if round == 0 {
|
if round == 0 {
|
||||||
"✨ Done (after auto-compact)"
|
"✨ Done (after auto-compact)"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue