From 71474831947645051075cc0c1b004d0d168de706 Mon Sep 17 00:00:00 2001 From: Maxime Rey <87315832+MaxJPRey@users.noreply.github.com> Date: Fri, 3 Dec 2021 18:08:45 +0100 Subject: [PATCH] Set the encoding 'utf-8'. (#624) --- pyaedt/desktop.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyaedt/desktop.py b/pyaedt/desktop.py index 9e8891f0839..50949b43e6f 100644 --- a/pyaedt/desktop.py +++ b/pyaedt/desktop.py @@ -440,7 +440,7 @@ def _get_tasks_list_windows(self, student_version): p = subprocess.Popen('tasklist /FI "IMAGENAME eq {}" /v'.format(process), stdout=subprocess.PIPE) result = p.communicate() - output = result[0].decode(encoding=sys.stdout.encoding, errors='ignore').split(os.linesep) + output = result[0].decode(encoding="utf-8", errors='ignore').split(os.linesep) pattern = r"(?i)^(?:{})\s+?(\d+)\s+.+[\s|\\](?:{})\s+".format(process, username) for l in output: