]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
Log calls to teuthology-report more verbosely
authorZack Cerza <zack@cerza.org>
Thu, 19 Dec 2013 16:25:51 +0000 (10:25 -0600)
committerZack Cerza <zack@cerza.org>
Thu, 19 Dec 2013 16:29:30 +0000 (10:29 -0600)
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
teuthology/queue.py

index 254a31e752c304b5324a034a0d099d0c99c8d53c..1cedb11ecfef2b17fde4dbc59ea787c3d81d2f49 100644 (file)
@@ -219,12 +219,19 @@ def run_with_watchdog(process, job_config):
         # The job ran with a teuthology branch that may not have the reporting
         # feature. Let's call teuthology-report (which will be from the master
         # branch) to report the job manually.
-        cmd = "teuthology-report -r {run_name} -j {job_id}".format(
+        cmd = "teuthology-report -v -r {run_name} -j {job_id}".format(
             run_name=job_info['name'],
             job_id=job_info['job_id'])
         try:
-            subprocess.Popen(cmd, shell=True).wait()
-            log.warn("Reported results via the teuthology-report command")
+            log.debug("Executing %s" % cmd)
+            report_proc = subprocess.Popen(cmd, shell=True,
+                                           stdout=subprocess.PIPE,
+                                           stderr=subprocess.STDOUT)
+            while report_proc.poll() is None:
+                for line in report_proc.stdout.readlines():
+                    log.info(line)
+                time.sleep(1)
+            log.info("Reported results via the teuthology-report command")
         except Exception:
             log.exception("teuthology-report failed")
             #log.warn("Tried to run teuthology-report but it wasn't in $PATH")