summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Larson <chris_larson@mentor.com>2011-06-02 14:45:13 -0700
committerChris Larson <chris_larson@mentor.com>2011-06-02 14:45:13 -0700
commit12aef37618bc77fb5ef085d24ad85471fb85c111 (patch)
tree6111d4f34bd759abfd6a62280866bc2844e32bb5
parentd6a0ffdd583be3df734171d7e91d334f798a79ce (diff)
downloadbitbake-12aef37618bc77fb5ef085d24ad85471fb85c111.tar.gz
cooker: handle ExpansionError the same way we do ParseError
Signed-off-by: Chris Larson <chris_larson@mentor.com>
-rw-r--r--lib/bb/cooker.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py
index db6009568..548d0a7b1 100644
--- a/lib/bb/cooker.py
+++ b/lib/bb/cooker.py
@@ -1032,7 +1032,7 @@ def catch_parse_error(func):
def wrapped(fn, *args):
try:
return func(fn, *args)
- except (IOError, bb.parse.ParseError) as exc:
+ except (IOError, bb.parse.ParseError, bb.data_smart.ExpansionError) as exc:
parselog.critical("Unable to parse %s: %s" % (fn, exc))
sys.exit(1)
return wrapped
@@ -1151,7 +1151,7 @@ class CookerParser(object):
self.shutdown(clean=False)
bb.fatal('Unable to parse %s: %s' %
(exc.recipe, bb.exceptions.to_string(exc.realexception)))
- except bb.parse.ParseError as exc:
+ except (bb.parse.ParseError, bb.data_smart.ExpansionError) as exc:
bb.fatal(str(exc))
except SyntaxError as exc:
logger.error('Unable to parse %s', exc.recipe)