From 0759c7fb4824f06b2521a0a65147e8f98951acef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubom=C3=ADr=20Sedl=C3=A1=C5=99?= Date: Wed, 16 Mar 2016 18:16:24 +0100 Subject: [PATCH] [buildinstall] Add more debugging output MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When it fails, a traceback will be printed. Signed-off-by: Lubomír Sedlář --- pungi/phases/buildinstall.py | 3 +++ pungi/wrappers/kojiwrapper.py | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/pungi/phases/buildinstall.py b/pungi/phases/buildinstall.py index ae74153b..c3ffdedb 100644 --- a/pungi/phases/buildinstall.py +++ b/pungi/phases/buildinstall.py @@ -22,6 +22,7 @@ import pipes import tempfile import shutil import re +import traceback from kobo.threads import ThreadPool, WorkerThread from kobo.shortcuts import run @@ -386,9 +387,11 @@ class BuildinstallThread(WorkerThread): if not compose.can_fail(variant, arch, 'buildinstall'): raise else: + tb = traceback.format_exc() self.pool.log_info( '[FAIL] Buildinstall for variant %s arch %s failed, but going on anyway.\n%s' % (variant.uid if variant else 'None', arch, exc)) + self.pool.log_debug(tb) def worker(self, compose, arch, variant, cmd, num): runroot = compose.conf.get("runroot", False) diff --git a/pungi/wrappers/kojiwrapper.py b/pungi/wrappers/kojiwrapper.py index 5267eef0..9d476ca4 100644 --- a/pungi/wrappers/kojiwrapper.py +++ b/pungi/wrappers/kojiwrapper.py @@ -86,7 +86,7 @@ class KojiWrapper(object): contains the id, it will be captured and returned. """ task_id = None - retcode, output = run(command, can_fail=True, logfile=log_file) + retcode, output = run(command, can_fail=True, logfile=log_file, show_cmd=True) if "--task-id" in command: first_line = output.splitlines()[0] if re.match(r'^\d+$', first_line):