From 2428c60456d1292d053e0b926a9395f320e4bfa0 Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Sat, 29 Jun 2024 08:40:18 -0700 Subject: [PATCH] added debug output --- aider/mdstream.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/aider/mdstream.py b/aider/mdstream.py index 947777651..87c25f860 100755 --- a/aider/mdstream.py +++ b/aider/mdstream.py @@ -95,7 +95,12 @@ class MarkdownStream: show = lines[num_printed:num_lines] show = "".join(show) show = Text.from_ansi(show) - self.live.console.print(show) + try: + self.live.console.print(show) + except UnicodeEncodeError as err: + print(err) + print(show) + print(repr(show)) self.printed = lines[:num_lines]