Bug 9083

Summary: Extensible SDK: SDK installation ERROR: Unexpected tasks left over to be executed
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Bogdan Alexandru Voiculescu <bogdanx.a.voiculescu>
Component: devtools / tool chainAssignee: Paul Eggleton <bluelightning>
Status: RESOLVED FIXED QA Contact: Francisco Pedraza <francisco.j.pedraza.gonzalez>
Severity: normal    
Priority: Medium+ CC: jose.perez.carranza, meta.mr.watcher, meta.watcher
Version: 2.1   
Target Milestone: 2.2 M3   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: Don't know
Attachments:
Description Flags
conf auto file
none
local conf none

Description Bogdan Alexandru Voiculescu 2016-02-09 15:26:37 UTC
When installing beaglebone EXT SDK I got this error: 

I got another error when installing beaglebone build
NOTE: Tasks Summary: Attempted 665 tasks of which 91 didn't need to be rerun and all succeeded.
ERROR: Unexpected tasks left over to be executed:
   task 642 of 1900 (ID: 1321, /home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_fetch)
   task 952 of 1900 (ID: 1843, virtual:native:/home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_fetch)
   task 1045 of 1900 (ID: 1317, /home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_unpack)
   task 1404 of 1900 (ID: 1318, /home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_patch)
   task 1449 of 1900 (ID: 1839, virtual:native:/home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_unpack)
   task 1835 of 1900 (ID: 1324, /home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_populate_lic)
   task 1854 of 1900 (ID: 1840, virtual:native:/home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_patch)
   task 1877 of 1900 (ID: 1846, virtual:native:/home/yocto/poky_sdk_beaglebone/layers/poky/meta/recipes-core/dbus/dbus_1.10.6.bb, do_populate_lic)
Comment 1 Bogdan Alexandru Voiculescu 2016-02-10 14:30:13 UTC
I think it is a configuration mistake; I can reproduce it if I add manually an auto.conf file in conf directory. 
Still without this file it installs fine. 
I will investigate more on this (I will create an AB job with a task populate_sdk_ext).
Comment 2 Paul Eggleton 2016-02-10 20:12:21 UTC
That is bizarre - what are you putting in this auto.conf file?
Comment 3 Bogdan Alexandru Voiculescu 2016-02-11 08:55:52 UTC
This is the content. 

# WARNING: this configuration has been automatically generated and in
# most cases should not be edited. If you need more flexibility than
# this configuration provides, it is strongly suggested that you set
# up a proper instance of the full build system and use that instead.

INHERIT += "report-error"
DISTRO = "poky"
PACKAGE_CLASSES = "package_rpm package_deb package_ipk"
SDKMACHINE ?= "x86_64"
IMAGE_FSTYPES_append = "  tar.gz"
BB_TASK_NICE_LEVEL = "5"
BB_TASK_NICE_LEVEL_task-testimage = "0"
BB_TASK_IONICE_LEVEL = "2.7"
BB_TASK_IONICE_LEVEL_task-testimage = "2.1"
DL_DIR ?= "${TOPDIR}/downloads"
INHERIT += "own-mirrors"
SOURCE_MIRROR_URL = "file:////media/sstate/downloads"
SRCREV_pn-build-appliance-image = "${AUTOREV}"
MACHINE = "qemux86"
PREMIRRORS = ""
ADTREPO = "http://adtrepo.yoctoproject.org//2.0+snapshot"
Comment 4 Paul Eggleton 2016-02-16 04:41:57 UTC
I just tried with your auto.conf file and I cannot reproduce the issue with master.

Also, you said "beaglebone" and yet it clearly has MACHINE = "qemux86" in the auto.conf file you pasted - I guess that's being overridden by the local.conf file you're using? Can you attach that file?
Comment 5 Bogdan Alexandru Voiculescu 2016-02-16 07:08:39 UTC
Created attachment 2984 [details]
conf auto file
Comment 6 Bogdan Alexandru Voiculescu 2016-02-16 07:09:06 UTC
Created attachment 2985 [details]
local conf
Comment 7 Paul Eggleton 2016-02-17 01:48:14 UTC
So MACHINE is going to be "qemuarm" with the files you just posted, not "beaglebone" - since auto.conf is parsed first, and in local.conf you are setting MACHINE with ?= which will do nothing since a value is already set.
I also still can't reproduce this even with the new configuration.
Comment 8 Bogdan Alexandru Voiculescu 2016-02-17 10:01:40 UTC
So I created a core-image-minimal with beaglebone and when I ran populate_sdk_ext took the qemuarm value and things broken?
Comment 9 Paul Eggleton 2016-02-17 10:27:00 UTC
No, that in and of itself wouldn't break things, and in any event I had that configuration here and the problem didn't occur, so something else is causing it.
Comment 10 Paul Eggleton 2016-02-28 22:29:27 UTC
So I think we've established offline to the extent possible that this was a result of a shared sstate directory where the dbus sstate artifacts were removed by another user (possibly with bitbake -c cleansstate dbus), but the task was still stamped within the build of the SDK; gen-lockedsigs-cache doesn't error if an sstate archive is missing because at the moment it can't tell the difference between an sstate task where the archive should be present and a non-sstate task where it's expected that it won't.

The question is where does that leave us with this bug?
Comment 11 Paul Eggleton 2016-04-27 02:19:45 UTC
Moving to 2.2 - I think the only thing we can really do here is to have this error happen earlier, which means testing at build time that the SDK will be able to install properly.
Comment 12 Paul Eggleton 2016-07-22 12:45:08 UTC
I've added extra checks to detect this early with a better error message.