aboutsummaryrefslogtreecommitdiffstats
path: root/lib/bb/progress.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bb/progress.py')
-rw-r--r--lib/bb/progress.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/bb/progress.py b/lib/bb/progress.py
index d051ba019..9518be77f 100644
--- a/lib/bb/progress.py
+++ b/lib/bb/progress.py
@@ -94,12 +94,15 @@ class LineFilterProgressHandler(ProgressHandler):
while True:
breakpos = self._linebuffer.find('\n') + 1
if breakpos == 0:
- break
+ # for the case when the line with progress ends with only '\r'
+ breakpos = self._linebuffer.find('\r') + 1
+ if breakpos == 0:
+ break
line = self._linebuffer[:breakpos]
self._linebuffer = self._linebuffer[breakpos:]
# Drop any line feeds and anything that precedes them
lbreakpos = line.rfind('\r') + 1
- if lbreakpos:
+ if lbreakpos and lbreakpos != breakpos:
line = line[lbreakpos:]
if self.writeline(filter_color(line)):
super().write(line)
@@ -145,7 +148,7 @@ class MultiStageProgressReporter:
for tasks made up of python code spread across multiple
classes / functions - the progress reporter object can
be passed around or stored at the object level and calls
- to next_stage() and update() made whereever needed.
+ to next_stage() and update() made wherever needed.
"""
def __init__(self, d, stage_weights, debug=False):
"""