From b196ab57931f3c67efcb561df0c8a2fe7c0e76f9 Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Fri, 20 Aug 2021 00:37:21 +0300 Subject: [PATCH] Do not overwrite PYTHONIOENCODING if defined --- clearml_agent/commands/worker.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clearml_agent/commands/worker.py b/clearml_agent/commands/worker.py index 49e16e9..e134ec2 100644 --- a/clearml_agent/commands/worker.py +++ b/clearml_agent/commands/worker.py @@ -2194,7 +2194,7 @@ class Worker(ServiceCommandSection): ) # check if we need to add encoding to the subprocess - if sys.getfilesystemencoding() == 'ascii': + if sys.getfilesystemencoding() == 'ascii' and not os.environ.get("PYTHONIOENCODING"): os.environ["PYTHONIOENCODING"] = "utf-8" print("Starting Task Execution:\n".format(current_task.id))