Patchwork [bitbake-devel,18/94] bitbake: buildinfohelper: clearing up task order

login
register
mail settings
Submitter Alexandru DAMIAN
Date Sept. 24, 2013, 4:51 p.m.
Message ID <07219c6e7020e80121f217666c951e75d27173d6.1380041477.git.alexandru.damian@intel.com>
Download mbox | patch
Permalink /patch/58839/
State New
Headers show

Comments

Alexandru DAMIAN - Sept. 24, 2013, 4:51 p.m.
From: Alexandru DAMIAN <alexandru.damian@intel.com>

Moved code around so that the task order is issued only
on creating new task method, and not on get information.

Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
---
 bitbake/lib/bb/ui/buildinfohelper.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Patch

diff --git a/bitbake/lib/bb/ui/buildinfohelper.py b/bitbake/lib/bb/ui/buildinfohelper.py
index f7f98d8..c743751 100644
--- a/bitbake/lib/bb/ui/buildinfohelper.py
+++ b/bitbake/lib/bb/ui/buildinfohelper.py
@@ -130,11 +130,12 @@  class ORMWrapper(object):
 
     def create_task_object(self, task_information):
         # This needs to be imported after we have configured the Django settings file
+        self.task_order += 1
         identifier = task_information['recipe'].name + task_information['task_name']
 
         task_object = Task.objects.get_or_create(
                                 build=task_information['build'],
-                                order=task_information['order'],
+                                order=self.task_order,
                                 task_executed=task_information['task_executed'],
                                 outcome=task_information['outcome'],
                                 sstate_checksum=task_information['sstate_checksum'],