summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEd Bartosh <ed.bartosh@linux.intel.com>2015-09-22 10:34:52 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-09-23 22:41:03 +0100
commit0a69a8a18075c976ed8681d9d75529f8c2f48514 (patch)
tree256ac9322d4d4a3d01f7df233f7026a12e1cc0d1
parent93e4c9bb2393b1074f5a01e7eaaac742a59d8086 (diff)
downloadbitbake-0a69a8a18075c976ed8681d9d75529f8c2f48514.zip
toaster: store task name in Target objects
Information about a task is not stored in Target objects. This makes it impossible to correctly operate with the builds where task is specified. Storing taks name is an enabler for other fixes in UI and backend related to restarting builds. Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/toaster/bldcontrol/management/commands/runbuilds.py2
-rw-r--r--lib/toaster/orm/models.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/toaster/bldcontrol/management/commands/runbuilds.py b/lib/toaster/bldcontrol/management/commands/runbuilds.py
index 718e1441..5243a50f 100644
--- a/lib/toaster/bldcontrol/management/commands/runbuilds.py
+++ b/lib/toaster/bldcontrol/management/commands/runbuilds.py
@@ -118,7 +118,7 @@ class Command(NoArgsCommand):
br.save()
# transpose target information
for brtarget in br.brtarget_set.all():
- Target.objects.create(build = br.build, target= brtarget.target)
+ Target.objects.create(build=br.build, target=brtarget.target, task=brtarget.task)
# transpose the launch errors in ToasterExceptions
for brerror in br.brerror_set.all():
LogMessage.objects.create(build = br.build, level = LogMessage.EXCEPTION, message = brerror.errmsg)
diff --git a/lib/toaster/orm/models.py b/lib/toaster/orm/models.py
index e4d2e87a..883ecf4e 100644
--- a/lib/toaster/orm/models.py
+++ b/lib/toaster/orm/models.py
@@ -270,7 +270,7 @@ class Project(models.Model):
)
for t in self.projecttarget_set.all():
BRTarget.objects.create(req = br, target = t.target, task = t.task)
- Target.objects.create(build = br.build, target = t.target)
+ Target.objects.create(build = br.build, target = t.target, task = t.task)
for v in self.projectvariable_set.all():
BRVariable.objects.create(req = br, name = v.name, value = v.value)