Skip to content

Commit 2193a12

Browse files
author
Your Name
committed
Preserve TUI ref in child coder classes
1 parent 8740a04 commit 2193a12

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

cecli/coders/base_coder.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -332,6 +332,10 @@ async def create(
332332

333333
if res is not None:
334334
if from_coder:
335+
# Preserve TUI ref in all child coders
336+
if from_coder.tui:
337+
res.tui = from_coder.tui
338+
335339
if res.mcp_manager:
336340
# When switching to a non-agent coder, disconnect the "Local" MCP server
337341
# (which provides agent-only tools like tool calling and file editing)
@@ -3746,7 +3750,7 @@ def calculate_and_show_tokens_and_cost(self, messages, completion=None):
37463750
total_stats += " ↑↓"
37473751

37483752
if not self.get_active_model().info.get("input_cost_per_token"):
3749-
self.usage_report = tokens_report + "\n" + total_stats
3753+
self.usage_report = tokens_report + " " + total_stats
37503754
return
37513755

37523756
try:
@@ -3769,7 +3773,7 @@ def calculate_and_show_tokens_and_cost(self, messages, completion=None):
37693773
)
37703774

37713775
if cache_hit_tokens and cache_write_tokens:
3772-
sep = "\n"
3776+
sep = " "
37733777
else:
37743778
sep = " "
37753779

0 commit comments

Comments
 (0)