| Summary: | Zephyr kernel tests fail to start if python module pexpect is not installed | ||
|---|---|---|---|
| Product: | [Build System, Metadata & Runtime] Other YP Layers | Reporter: | Henry Bruce <henry.bruce> |
| Component: | meta-zephyr | Assignee: | Juro Bystricky <juro.bystricky> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | Medium | CC: | bluelightning, srifenbark |
| Version: | 2.3 | ||
| Target Milestone: | 2.3 M3 | ||
| Hardware: | x86 | ||
| OS: | Multiple | ||
| Whiteboard: | 24 Jan 2017: RESOLVED | ||
| OS type for building Yocto: | --- | Type of Regression: | --- |
| Verified: | Documentation change: | Done (doc changes complete) | |
The bug has actually nothing to do with meta-zephyr. It is the meta-yocto-bsp/lib/oeqa/controllers/beaglebonetarget.py complaining about missing python module "pexpect". I could speculate the module was previously included with python2.7 by default but it is not installed by python3, at least for some Linux distros. However, I suspect this problem has always been there. Manual installation : $ sudo pip3 install pexpect should fix the problem. So the most prudent fix is to update the documentation explicitly stating pexpect is required http://www.yoctoproject.org/docs/1.8/ref-manual/ref-manual.html#required-packages-for-the-host-development-system Punting this to Scott, as the need for "pexpect" should be documented. Juro, So installing the "pexpect" package for all supported distros. I assume that it needs to be in the "Essentials" grouping (see http://www.yoctoproject.org/docs/2.3/ref-manual/ref-manual.html#required-packages-for-the-host-development-system) Thanks, Scott yes, I believe that is exactly what is needed. Juro, See http://www.yoctoproject.org/docs/2.3/ref-manual/ref-manual.html#required-packages-for-the-host-development-system for the changes in the ref-manual. See http://www.yoctoproject.org/docs/2.3/yocto-project-qs/yocto-project-qs.html#packages for the similar section in the YP Quick Start. If this is ok - let me know. Thanks, Scott Looks good to me. (And it should be probably back ported to previous Yocto documentation as well, this is not a new requirement) Backported to top of yocto-docs/morty branch. See ref-manual at http://www.yoctoproject.org/docs/2.2.1/ref-manual/ref-manual.html#required-packages-for-the-host-development-system Backported to top of yocto-docs/morty branch. see YP Quick Start at http://www.yoctoproject.org/docs/2.2.1/yocto-project-qs/yocto-project-qs.html#packages Scott Looks fine. Both pip3 and pexpect are always needed: pip3 in order to run toaster and build Build Appliance pexpect is (and has always been) needed by beaglbone testimage Thanks Juro, I am setting the bug to RESOLVED and putting the doc flag to "done." Scott |
Observed behavior ================= Kernel tests will not run if python module pexpect is not installed $ bitbake zephyr-kernel-test-all -ctestimage ERROR: zephyr-kernel-test-test-nano-work-1.6.0-r0 do_testimage: Failed to import QemuTargetZephyr from available controller modules: Traceback (most recent call last): File "/path/to/poky/meta/lib/oeqa/targetcontrol.py", line 32, in get_target_controller controller = getattr(sys.modules[__name__], testtarget) AttributeError: module 'oeqa.targetcontrol' has no attribute 'QemuTargetZephyr' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/path/to/poky/meta/lib/oeqa/targetcontrol.py", line 38, in get_target_controller controller = testtargetloader.get_controller_module(testtarget, bbpath) File "/path/to/poky/meta/lib/oeqa/controllers/testtargetloader.py", line 15, in get_controller_module controller = self.load_controller_from_name(target, controllerslist) File "path/to/poky/meta/lib/oeqa/controllers/testtargetloader.py", line 48, in load_controller_from_name obj = self.load_controller_from_module(target, name) File "/path/to/poky/meta/lib/oeqa/controllers/testtargetloader.py", line 57, in load_controller_from_module module = __import__(modulename, globals(), locals(), [target]) File "/path/to/poky/meta-yocto-bsp/lib/oeqa/controllers/beaglebonetarget.py", line 25, in <module> import pexpect ImportError: No module named 'pexpect' ERROR: zephyr-kernel-test-test-nano-work-1.6.0-r0 do_testimage: Function failed: do_testimage ERROR: Logfile of failure stored in: /path/to/build/tmp/work/i586-yocto-elf/zephyr-kernel-test-test-nano-work/1.6.0-r0/temp/log.do_testimage.27044 Expected behavior ================= Documentation states that python module pexpect must be installed.