diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-12 08:15:34 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-12 23:01:03 +0100 |
commit | 9a4db1aa608c17d31bf5ea1cab5a99beb565dd83 (patch) | |
tree | 3663fa7e263c9200351acaaafbd06afcbab84e17 /lib/bb/main.py | |
parent | b90a16408a5c45ce5312384f278e19d09f8dda4d (diff) | |
download | bitbake-contrib-9a4db1aa608c17d31bf5ea1cab5a99beb565dd83.tar.gz |
main: Ensure exceptions are correctly displayed
If the cooker fails to start, ensure a correct exception is displayed to the
user. After handling any queued events simply re-raise the original exception
else the output can be unclear.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/bb/main.py')
-rwxr-xr-x | lib/bb/main.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/bb/main.py b/lib/bb/main.py index eb15779fa..761ea459c 100755 --- a/lib/bb/main.py +++ b/lib/bb/main.py @@ -335,7 +335,6 @@ def start_server(servermodule, configParams, configuration, features): server.addcooker(cooker) server.saveConnectionDetails() except Exception as e: - exc_info = sys.exc_info() while hasattr(server, "event_queue"): try: import queue @@ -347,7 +346,7 @@ def start_server(servermodule, configParams, configuration, features): break if isinstance(event, logging.LogRecord): logger.handle(event) - raise exc_info[1], None, exc_info[2] + raise server.detach() cooker.lock.close() return server |