From: Peter Amstutz Date: Tue, 1 Jul 2014 17:50:31 +0000 (-0400) Subject: Improve error messages X-Git-Tag: 1.1.0~2482^2~4 X-Git-Url: https://git.arvados.org/arvados.git/commitdiff_plain/9cb30aa6a84d5b3c7a3ae0d4fc398d64cbd6c306 Improve error messages --- diff --git a/crunch_scripts/run-command b/crunch_scripts/run-command index aa50cde4d7..39357d4d9e 100755 --- a/crunch_scripts/run-command +++ b/crunch_scripts/run-command @@ -50,12 +50,14 @@ try: stdoutname = subst.do_substitution(p, p["stdout"]) stdoutfile = open(stdoutname, "wb") - print("Running command: {}{}".format(' '.join(cmd), (" > " + stdoutname) if stdoutname != None else "")) + print("run-command running: {}{}".format(' '.join(cmd), (" > " + stdoutname) if stdoutname != None else "")) rcode = subprocess.call(cmd, stdout=stdoutfile) + print("run-command completed with exit code %i" % rcode) + except Exception as e: - print("Caught exception {}".format(e)) + print("run-command exception: {}".format(e)) finally: for l in links: