From 12d1e9be6516d3aa7ea788e7736a9aa3a3656be3 Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Sat, 4 Feb 2023 12:42:56 +0100 Subject: [PATCH] pipeline was failing with decode error I could not reproduce it, maybe this helps --- python/tests/test_Result.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/tests/test_Result.py b/python/tests/test_Result.py index 16092aeba..1e95c95de 100644 --- a/python/tests/test_Result.py +++ b/python/tests/test_Result.py @@ -397,8 +397,8 @@ class TestResult: v = VTK.load(tmp_path/fname) v.comments = ['n/a'] v.save(tmp_path/fname,parallel=False) - with open(tmp_path/fname) as f: - cur = hashlib.md5(f.read().encode()).hexdigest() + with open(tmp_path/fname,'rb') as f: + cur = hashlib.md5(f.read()).hexdigest() if update: with open((ref_path/'export_VTK'/request.node.name).with_suffix('.md5'),'w') as f: f.write(cur+'\n')