Commit e62f7ad0 authored by Valentin Reis's avatar Valentin Reis

[fix] Printing application stdout and stderr correctly (with tangling of cmd log on stderr.)

parent 14766d2d
Pipeline #4828 failed with stages
in 1 minute and 8 seconds
......@@ -118,13 +118,17 @@ class CommandLineInterface(object):
assert msg.type in ['stdout', 'stderr', 'exit', 'process_exit']
if msg.type == 'stdout':
logger.info("container msg: %r", msg)
logger.debug("container msg: %r", msg)
if msg.payload == 'eof':
outeof = True
else:
print(msg.payload)
elif msg.type == 'stderr':
logger.info("container msg: %r", msg)
logger.debug("container msg: %r", msg)
if msg.payload == 'eof':
erreof = True
else:
print(msg.payload, file=sys.stderr)
elif msg.type == 'process_exit':
logger.info("process ended: %r", msg)
state = 'exiting'
......
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