Author: Jonas Devlieghere Date: 2020-11-03T11:51:40-08:00 New Revision: f0fd4349a78aff99b7e2214bf1ffe9e352201de3
URL: https://github.com/llvm/llvm-project/commit/f0fd4349a78aff99b7e2214bf1ffe9e352201de3 DIFF: https://github.com/llvm/llvm-project/commit/f0fd4349a78aff99b7e2214bf1ffe9e352201de3.diff LOG: [crashlog] Print the actual exception in the CommandReturnObject Before: error: python exception <class 'AttributeError'> After: error: python exception: 'DarwinImage' object has no attribute 'debugger' Added: Modified: lldb/examples/python/crashlog.py Removed: ################################################################################ diff --git a/lldb/examples/python/crashlog.py b/lldb/examples/python/crashlog.py index 76538715f17e..d3943fb3f0fe 100755 --- a/lldb/examples/python/crashlog.py +++ b/lldb/examples/python/crashlog.py @@ -849,8 +849,8 @@ def save_crashlog(debugger, command, exe_ctx, result, dict): def Symbolicate(debugger, command, result, dict): try: SymbolicateCrashLogs(shlex.split(command)) - except: - result.PutCString("error: python exception %s" % sys.exc_info()[0]) + except Exception as e: + result.PutCString("error: python exception: %s" % e) def SymbolicateCrashLog(crash_log, options): _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits