aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz>2023-07-06 12:47:42 +0200
committerMarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz>2023-07-20 09:15:29 +0200
commitfa6bb85cd264adf2e1f0c71fa97b650f9a62745f (patch)
treef0130b3020a9f657161c5fa78d55435b4e5bd698 /test
parentfa63326fbc1634ef2816f79c54db9266e56f4b3b (diff)
downloadbitcoin-fa6bb85cd264adf2e1f0c71fa97b650f9a62745f.tar.xz
test: Ignore UTF-8 errors in assert_debug_log
read() fails in text mode when the unicode hasn't been fully written yet. Fixes: "wallet_importdescriptors.py: can't decode bytes in position 228861-228863: unexpected end of data" (https://github.com/bitcoin/bitcoin/issues/28030)
Diffstat (limited to 'test')
-rwxr-xr-xtest/functional/test_framework/test_node.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/functional/test_framework/test_node.py b/test/functional/test_framework/test_node.py
index f2ef17ccb7..7ef3280ffc 100755
--- a/test/functional/test_framework/test_node.py
+++ b/test/functional/test_framework/test_node.py
@@ -440,7 +440,7 @@ class TestNode():
while True:
found = True
- with open(self.debug_log_path, encoding='utf-8') as dl:
+ with open(self.debug_log_path, encoding="utf-8", errors="replace") as dl:
dl.seek(prev_size)
log = dl.read()
print_log = " - " + "\n - ".join(log.splitlines())