mirror of
https://github.com/xcat2/confluent.git
synced 2024-11-25 11:01:09 +00:00
Have confetty show correct trace more easily
In some scenarios, the quitconfetty will overwrite the stack trace. Get the relevant trace before trying the quitconfetty, then print the saved trace.
This commit is contained in:
parent
23dffe882e
commit
e08ca5fb7e
@ -1024,11 +1024,12 @@ if __name__ == '__main__':
|
||||
errcode = e.errorcode
|
||||
except Exception as e:
|
||||
import traceback
|
||||
excinfo = traceback.print_exc()
|
||||
try:
|
||||
quitconfetty()
|
||||
except Exception:
|
||||
pass
|
||||
traceback.print_exc()
|
||||
print(excinfo)
|
||||
finally:
|
||||
if deadline and os.times()[4] < deadline:
|
||||
sys.stderr.write('[Exited early, hit enter to continue]')
|
||||
|
Loading…
Reference in New Issue
Block a user