Comments
Patch
@@ -97,7 +97,10 @@ class TerminalFilter2(object):
if self.main.shutdown:
print("Waiting for %s running tasks to finish:" % len(activetasks))
else:
- print("Currently %s running tasks (%s of %s):" % (len(activetasks), self.helper.tasknumber_current, self.helper.tasknumber_total))
+ if self.helper.tasknumber_current == 0:
+ print("Currently %s running SetScene tasks (%s of %s):" % (len(activetasks), self.helper.sc_tasknumber_current, self.helper.sc_tasknumber_total))
+ else:
+ print("Currently %s running tasks (%s of %s):" % (len(activetasks), self.helper.tasknumber_current, self.helper.tasknumber_total))
for tasknum, task in enumerate(tasks):
print("%s: %s" % (tasknum, task))
lines = lines + 1
@@ -28,6 +28,8 @@ class BBUIHelper:
self.failed_tasks = []
self.tasknumber_current = 0
self.tasknumber_total = 0
+ self.sc_tasknumber_current = 0
+ self.sc_tasknumber_current = 0
def eventHandler(self, event):
if isinstance(event, bb.build.TaskStarted):
@@ -48,6 +50,9 @@ class BBUIHelper:
self.running_pids.remove(event.pid)
self.failed_tasks.append( { 'title' : "%s %s" % (event._package, event._task)})
self.needUpdate = True
+ if isinstance(event, bb.runqueue.sceneQueueTaskStarted):
+ self.sc_tasknumber_current = event.stats.completed + event.stats.active + event.stats.failed + 1
+ self.sc_tasknumber_total = event.stats.total
if isinstance(event, bb.runqueue.runQueueTaskStarted):
self.tasknumber_current = event.stats.completed + event.stats.active + event.stats.failed + 1
self.tasknumber_total = event.stats.total
Any time knotty2 was running through the setscene tasks it was always reporting the top line as follows for a core-image-minimal build. Currently 7 running tasks (0 of 0): With this patch the number of SetScene tasks are tracked and reported with knotty such that it nows looks something like: Currently 7 running SetScene tasks (342 of 479): Signed-off-by: Jason Wessel <jason.wessel@windriver.com> --- lib/bb/ui/knotty2.py | 5 ++++- lib/bb/ui/uihelper.py | 5 +++++ 2 files changed, 9 insertions(+), 1 deletion(-)