My HOSTTOOLS were missing "chrpath", so an error message was expected. However, not like this: ERROR: Unable to start bitbake server (None) ERROR: Server log for this session (/home/juro/yocto/poky/build2-repro-minimal-x86_64-2019-04-04/bitbake-cookerdaemon.log): --- Starting bitbake server pid 14471 at 2019-04-04 10:42:45.831093 --- Traceback (most recent call last): File "/home/juro/yocto/poky/bitbake/lib/bb/cookerdata.py", line 290, in parseBaseConfiguration bb.event.fire(bb.event.ConfigParsed(), self.data) File "/home/juro/yocto/poky/bitbake/lib/bb/event.py", line 225, in fire fire_class_handlers(event, d) File "/home/juro/yocto/poky/bitbake/lib/bb/event.py", line 134, in fire_class_handlers execute_handler(name, handler, event, d) File "/home/juro/yocto/poky/bitbake/lib/bb/event.py", line 106, in execute_handler ret = handler(event) File "/home/juro/yocto/poky/meta/classes/base.bbclass", line 238, in base_eventhandler setup_hosttools_dir(d.getVar('HOSTTOOLS_DIR'), 'HOSTTOOLS', d) File "/home/juro/yocto/poky/meta/classes/base.bbclass", line 142, in setup_hosttools_dir bb.fatal("The following required tools (as specified by HOSTTOOLS) appear to be unavailable in PATH, please install them in order to proceed:\n %s" % " ".join(notfound)) File "/home/juro/yocto/poky/bitbake/lib/bb/__init__.py", line 120, in fatal raise BBHandledException() bb.BBHandledException During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/juro/yocto/poky/bitbake/lib/bb/daemonize.py", line 83, in createDaemon function() File "/home/juro/yocto/poky/bitbake/lib/bb/server/process.py", line 469, in _startServer self.cooker = bb.cooker.BBCooker(self.configuration, self.featureset) File "/home/juro/yocto/poky/bitbake/lib/bb/cooker.py", line 210, in __init__ self.initConfigurationData() File "/home/juro/yocto/poky/bitbake/lib/bb/cooker.py", line 375, in initConfigurationData self.databuilder.parseBaseConfiguration() File "/home/juro/yocto/poky/bitbake/lib/bb/cookerdata.py", line 317, in parseBaseConfiguration raise bb.BBHandledException bb.BBHandledException ERROR: The following required tools (as specified by HOSTTOOLS) appear to be unavailable in PATH, please install them in order to proceed: chrpath
Hi RP, I think that double exceptions are acceptable unless it loses error message? For this case, the error message is kept. What's your opinion, please ?
The double exception is confusing to the user. The system printed a real error so it shouldn't be printing an exception at all in this case. One of the points of bb.BBHandledException is to avoid tracebacks as there should have been a usable error shown to the user already.
Merged into master: http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=2cb6a75b5ad54fb4224a41a65a4f2bcc902f5b94