Skip to content
Snippets Groups Projects
Commit a85b1383 authored by Daniel Brown's avatar Daniel Brown
Browse files

changing output parsing

parent 249a90ea
No related branches found
No related tags found
No related merge requests found
......@@ -382,7 +382,6 @@ class kat(object):
"""
start = datetime.datetime.now()
try:
if not hasattr(self, "xaxis") and self.noxaxis != None and self.noxaxis == False:
raise pkex.BasePyKatException("No xaxis was defined")
......@@ -453,17 +452,28 @@ class kat(object):
for line in iter(p.stderr.readline, ""):
if len(line) > 0:
if line.rstrip().endswith('%'):
if line.rstrip().endswith('s'):
vals = line.split("-")
action = vals[0].strip()
prc = vals[1].strip()[:-1]
prc = vals[1].strip()[:]
if printerr == 1:
sys.stdout.write("\r{0} {1}%".format(action, prc))
sys.stdout.write("\r{0} {1}".format(action, prc))
elif line.rstrip().endswith('%'):
vals = line.split("-")
action = vals[0].strip()
prc = vals[1].strip()[:]
if printerr == 1:
sys.stdout.write("\r{0} {1}".format(action, prc))
elif line[0:3] == '** ':
if self.verbose: sys.stdout.write(line)
else:
err += line
[out,errpipe] = p.communicate()
if printout == 1:
print out
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment