From 3cf7a984fde49b59d68b73cc2ac4c6573bf1e669 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Mon, 10 Oct 2022 19:50:43 +0530 Subject: [PATCH] Convert bytes to str in the output of run --- installer/installer/helpers.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/installer/installer/helpers.py b/installer/installer/helpers.py index 31c73f8d..a1bc9387 100644 --- a/installer/installer/helpers.py +++ b/installer/installer/helpers.py @@ -20,6 +20,9 @@ def run(cmd, run_in_folder=None, env=None, get_output=False, log_the_cmd=False): out, err = p.communicate() + out = out.decode('utf-8') if isinstance(out, bytes) else out + err = err.decode('utf-8') if isinstance(out, bytes) else err + if get_output: return out, err