From 475e3ee3f26c944b48b7391d73e56f37965bd704 Mon Sep 17 00:00:00 2001 From: Randy Syring Date: Thu, 20 Dec 2018 20:10:05 -0500 Subject: [PATCH] fix json bytes/text for Python 3.5 Apparently json.loads() can only handle bytes in 3.6+. --- diskbench/fio.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/diskbench/fio.py b/diskbench/fio.py index ee501a9..ba0510c 100644 --- a/diskbench/fio.py +++ b/diskbench/fio.py @@ -32,7 +32,7 @@ def fio(dpath, loops, size): assert not result.stderr, result.stderr - fio_data = json.loads(result.stdout) + fio_data = json.loads(result.stdout.decode('utf-8')) return extract_stats(fio_data)