diff options
author | Chris Larson <chris_larson@mentor.com> | 2011-05-06 07:15:34 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-06-08 20:38:25 +0100 |
commit | e12105474017262d176dbaaecdc3f90f155aa8df (patch) | |
tree | 37321dee5c87f859596b116eef15ba665eb1bd07 /bitbake | |
parent | 97504f2bc865c3c2dc94fb8bdd3d2e3a027647dd (diff) | |
download | poky-e12105474017262d176dbaaecdc3f90f155aa8df.tar.gz |
cooker: don't show a useless traceback for SyntaxError
Note: we rely on the fact that better_compile has already output information
about the exception, so don't do it ourselves.
(Bitbake rev: caf21e9fbf3c526c1d7c555d8c76dca8710f9def)
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rw-r--r-- | bitbake/lib/bb/cooker.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py index 293ad355b8..f4836509ca 100644 --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py | |||
@@ -1227,7 +1227,10 @@ class CookerParser(object): | |||
1227 | self.shutdown(clean=False) | 1227 | self.shutdown(clean=False) |
1228 | bb.fatal('Error parsing %s: %s' % | 1228 | bb.fatal('Error parsing %s: %s' % |
1229 | (exc.recipe, bb.exceptions.to_string(exc.realexception))) | 1229 | (exc.recipe, bb.exceptions.to_string(exc.realexception))) |
1230 | except Exception: | 1230 | except SyntaxError as exc: |
1231 | logger.error('Unable to parse %s', exc.recipe) | ||
1232 | sys.exit(1) | ||
1233 | except Exception as exc: | ||
1231 | import traceback | 1234 | import traceback |
1232 | etype, value, tb = sys.exc_info() | 1235 | etype, value, tb = sys.exc_info() |
1233 | formatted = bb.exceptions.format_extracted(value.traceback, limit=5) | 1236 | formatted = bb.exceptions.format_extracted(value.traceback, limit=5) |