Because the qemu sanity tests need to open windows under Xorg, the DISPLAY variable needs to be set. If IMAGETEST is set in local.conf but DISPLAY is not, the following python error will occur: Source: http://autobuilder.pokylinux.org:8010/builders/poky-incremental/builds/29/steps/shell_20/logs/stdio NOTE: package poky-image-lsb-1.0-r0: task do_qemuimagetest: Started ERROR: There was an error when executing a python function in: /builds1/pokybuild/poky-slave/poky-incremental/build/meta/recipes-extended/images/poky-image-lsb.bb ERROR: Exception:<type 'exceptions.TypeError'> Message:putenv() argument 2 must be string, not None ERROR: The stack trace of python calls that resulted in thie exception/failure was: ERROR: File "do_qemuimagetest", line 4, in <module> ERROR: ERROR: File "do_qemuimagetest", line 2, in do_qemuimagetest ERROR: ERROR: File "imagetest-qemu.bbclass", line 111, in qemuimagetest_main ERROR: ERROR: File "imagetest-qemu.bbclass", line 34, in runtest ERROR: ERROR: File "/usr/lib64/python2.6/os.py", line 471, in __setitem__ ERROR: putenv(key, item) ERROR: ERROR: The code that was being executed was: ERROR: 0001:def do_qemuimagetest(d): ERROR: 0002: qemuimagetest_main(d) ERROR: 0003: ERROR: *** 0004:do_qemuimagetest(d) ERROR: (file: 'do_qemuimagetest', lineno: 4, function: <module>) ERROR: 0001:def do_qemuimagetest(d): ERROR: *** 0002: qemuimagetest_main(d) ERROR: 0003: ERROR: 0004:do_qemuimagetest(d) ERROR: (file: 'do_qemuimagetest', lineno: 2, function: do_qemuimagetest) ERROR: Task failed: ('Function do_qemuimagetest failed', '/builds1/pokybuild/poky-slave/poky-incremental/build/build/tmp/work/qemuarm-poky-linux-gnueabi/poky-image-lsb-1.0-r0/temp/log.do_qemuimagetest.5017') ERROR: Logfile of failure stored in: /builds1/pokybuild/poky-slave/poky-incremental/build/build/tmp/work/qemuarm-poky-linux-gnueabi/poky-image-lsb-1.0-r0/temp/log.do_qemuimagetest.5017 Log data follows: | ERROR: There was an error when executing a python function in: /builds1/pokybuild/poky-slave/poky-incremental/build/meta/recipes-extended/images/poky-image-lsb.bb | ERROR: Exception:<type 'exceptions.TypeError'> Message:putenv() argument 2 must be string, not None | ERROR: The stack trace of python calls that resulted in thie exception/failure was: | ERROR: File "do_qemuimagetest", line 4, in <module> | ERROR: | ERROR: File "do_qemuimagetest", line 2, in do_qemuimagetest | ERROR: | ERROR: File "imagetest-qemu.bbclass", line 111, in qemuimagetest_main | ERROR: | ERROR: File "imagetest-qemu.bbclass", line 34, in runtest | ERROR: | ERROR: File "/usr/lib64/python2.6/os.py", line 471, in __setitem__ | ERROR: putenv(key, item) | ERROR: | ERROR: The code that was being executed was: | ERROR: 0001:def do_qemuimagetest(d): | ERROR: 0002: qemuimagetest_main(d) | ERROR: 0003: | ERROR: *** 0004:do_qemuimagetest(d) | ERROR: (file: 'do_qemuimagetest', lineno: 4, function: <module>) | ERROR: 0001:def do_qemuimagetest(d): | ERROR: *** 0002: qemuimagetest_main(d) | ERROR: 0003: | ERROR: 0004:do_qemuimagetest(d) | ERROR: (file: 'do_qemuimagetest', lineno: 2, function: do_qemuimagetest) | ERROR: Task failed: ('Function do_qemuimagetest failed', '/builds1/pokybuild/poky-slave/poky-incremental/build/build/tmp/work/qemuarm-poky-linux-gnueabi/poky-image-lsb-1.0-r0/temp/log.do_qemuimagetest.5017') To fix this, Richard suggested that we should error out immediately if this condition is detected. This is something that could be added to sanity.bbclass.
Fixed in commit b99fd0374e554f4d2183f349f271220951299c9a
Verified that the following error is displayed when IMAGETEST is set but DISPLAY is not: "qemuimagetest needs a X desktop to start qemu, please set DISPLAY correctly (e.g. DISPLAY=:1.0)"