mirror of
https://git.yoctoproject.org/poky
synced 2026-04-29 09:32:11 +02:00
devtool: use DevtoolError for error handling
Use DevtoolError exception more widely for handling error cases. This exception is now caught in the main script and raising it can be used to exit with an error. This hopefully simplifies error handling. The change also makes exit codes more consistent, always returning '1' when an error occurs. (From OE-Core rev: 2e4f1dcade7ccb581c7a390c32163ea3deeac6d5) Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
5648a7909f
commit
07f76656d9
@@ -25,6 +25,12 @@ import logging
|
||||
|
||||
logger = logging.getLogger('devtool')
|
||||
|
||||
|
||||
class DevtoolError(Exception):
|
||||
"""Exception for handling devtool errors"""
|
||||
pass
|
||||
|
||||
|
||||
def exec_build_env_command(init_path, builddir, cmd, watch=False, **options):
|
||||
"""Run a program in bitbake build context"""
|
||||
import bb
|
||||
|
||||
Reference in New Issue
Block a user