aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/lib/devtool/__init__.py
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2017-02-01 09:56:14 +1300
committerPaul Eggleton <paul.eggleton@linux.intel.com>2017-02-07 09:43:52 +1300
commit785518d6e6f7190350fb858867684d2f70d4671a (patch)
tree8a9a48555dbf0eaac1b9d0829a33ea6e7f338e0c /scripts/lib/devtool/__init__.py
parentede21e1bb24714c94f2fe7a97749127a03ccd8fb (diff)
downloadopenembedded-core-contrib-785518d6e6f7190350fb858867684d2f70d4671a.tar.gz
devtool: improve parse failure handlingpaule/devtool25
With the move to tinfoil2, the behaviour when parsing failed has changed a bit - exceptions are now raised, so handle these appropriately. Specifically when if parsing the recipe created when running devtool add fails, rename it to .bb.parsefailed so that the user can run bitbake afterwards without parsing being interrupted. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Diffstat (limited to 'scripts/lib/devtool/__init__.py')
-rw-r--r--scripts/lib/devtool/__init__.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/scripts/lib/devtool/__init__.py b/scripts/lib/devtool/__init__.py
index fd2f042ba5..91111e1109 100644
--- a/scripts/lib/devtool/__init__.py
+++ b/scripts/lib/devtool/__init__.py
@@ -135,7 +135,12 @@ def parse_recipe(config, tinfoil, pn, appends, filter_workspace=True):
not path.startswith(config.workspace_path)]
else:
append_files = None
- return tinfoil.parse_recipe_file(recipefile, appends, append_files)
+ try:
+ rd = tinfoil.parse_recipe_file(recipefile, appends, append_files)
+ except Exception as e:
+ logger.error(str(e))
+ return None
+ return rd
def check_workspace_recipe(workspace, pn, checksrc=True, bbclassextend=False):
"""