summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/cookerdata.py
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb/cookerdata.py')
-rw-r--r--bitbake/lib/bb/cookerdata.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/bitbake/lib/bb/cookerdata.py b/bitbake/lib/bb/cookerdata.py
index b20040c0b3..f19c283884 100644
--- a/bitbake/lib/bb/cookerdata.py
+++ b/bitbake/lib/bb/cookerdata.py
@@ -180,7 +180,16 @@ def catch_parse_error(func):
180 parselog.critical("Unable to parse %s: %s" % (fn, exc)) 180 parselog.critical("Unable to parse %s: %s" % (fn, exc))
181 sys.exit(1) 181 sys.exit(1)
182 except (bb.parse.ParseError, bb.data_smart.ExpansionError) as exc: 182 except (bb.parse.ParseError, bb.data_smart.ExpansionError) as exc:
183 parselog.critical("Unable to parse %s: %s" % (fn, exc)) 183 import traceback
184
185 bbdir = os.path.dirname(__file__) + os.sep
186 exc_class, exc, tb = sys.exc_info()
187 for tb in iter(lambda: tb.tb_next, None):
188 # Skip frames in bitbake itself, we only want the metadata
189 fn, _, _, _ = traceback.extract_tb(tb, 1)[0]
190 if not fn.startswith(bbdir):
191 break
192 parselog.critical("Unable to parse %s", fn, exc_info=(exc_class, exc, tb))
184 sys.exit(1) 193 sys.exit(1)
185 return wrapped 194 return wrapped
186 195