Commit 8881dfdd authored by Valentin Reis's avatar Valentin Reis
Browse files

[bugfix] status-based Traceback on `cmd run` invocations

This converts the return status to int before running the
introspection logic and fixes the issue.
parent 6d8ae62f
Pipeline #6497 failed with stages
in 3 minutes and 14 seconds
......@@ -171,13 +171,14 @@ class CommandLineInterface(object):
logger.error("unexpected message: %r", msg)
if outeof and erreof and state == 'exiting':
state = 'exit'
istatus = int(exitmsg.status)"command ended: %r", exitmsg)
if os.WIFSIGNALED(exitmsg.status):
if os.WIFSIGNALED(istatus):
logger.error("command ended due to signal %s" %
elif os.WIFEXITED(exitmsg.status):
s = int(os.WTERMSIG(exitmsg.status))
elif os.WIFEXITED(istatus):
s = int(os.WTERMSIG(istatus))
if s > 0:
logger.debug("command ended with exit code %s" %
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment