From e84e884d6643bdfaea5a5317dcce14c29e304c16 Mon Sep 17 00:00:00 2001 From: Alexey Lapshin Date: Mon, 22 May 2023 20:18:02 +0800 Subject: [PATCH] tools: fix control characters print if hints enabled Closes https://github.com/espressif/esp-idf/issues/11351 --- tools/idf_py_actions/tools.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/idf_py_actions/tools.py b/tools/idf_py_actions/tools.py index f0bd8814ed..aac3610635 100644 --- a/tools/idf_py_actions/tools.py +++ b/tools/idf_py_actions/tools.py @@ -289,7 +289,7 @@ class RunTool: if len(buffer) > 4: # Multi-byte character contain up to 4 bytes and if buffer have more then 4 bytes # and still can not decode it we can just ignore some bytes - return buffer.decode(errors='ignore') + return buffer.decode(errors='replace') # use ANSI color converter for Monitor on Windows output_converter = get_ansi_converter(output_stream) if self.convert_output else output_stream