]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
teuthology/repo_util: pass universal_newlines=True 1752/head
authorKefu Chai <tchaikov@gmail.com>
Wed, 27 Apr 2022 01:46:48 +0000 (09:46 +0800)
committerKefu Chai <tchaikov@gmail.com>
Wed, 27 Apr 2022 01:46:51 +0000 (09:46 +0800)
for better readability

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
teuthology/repo_utils.py

index 703eb9739e530951246b402a6905e0e5fc08ac5c..707edda3db6a9de5cdee29c032f6f52e35e2d2dc 100644 (file)
@@ -425,12 +425,13 @@ def bootstrap_teuthology(dest_path):
         cmd = './bootstrap'
         boot_proc = subprocess.Popen(cmd, shell=True, cwd=dest_path, env=env,
                                      stdout=subprocess.PIPE,
-                                     stderr=subprocess.STDOUT)
+                                     stderr=subprocess.STDOUT,
+                                     universal_newlines=True)
         out, err = boot_proc.communicate()
         returncode = boot_proc.wait()
         log.info("Bootstrap exited with status %s", returncode)
         if returncode != 0:
-            for line in out.decode().split("\n"):
+            for line in out.split("\n"):
                 log.warning(line.strip())
             venv_path = os.path.join(dest_path, 'virtualenv')
             log.info("Removing %s", venv_path)