Made crash_gen more tolerable of TAOS exceptions

This commit is contained in:
Steven Li 2020-07-09 07:23:36 +00:00
parent b77728bc0d
commit f35c6cf3d8
1 changed files with 7 additions and 7 deletions

View File

@ -1227,8 +1227,8 @@ class Task():
errMsg = "[=] Unexpected Taos library exception: errno=0x{:X}, msg: {}, SQL: {}".format(errno2, err, self._lastSql) errMsg = "[=] Unexpected Taos library exception: errno=0x{:X}, msg: {}, SQL: {}".format(errno2, err, self._lastSql)
self.logDebug(errMsg) self.logDebug(errMsg)
if gConfig.debug : if gConfig.debug :
raise # so that we see full stack # raise # so that we see full stack
else: # non-debug traceback.print_exc()
print("\n\n----------------------------\nProgram ABORTED Due to Unexpected TAOS Error: \n\n{}\n".format(errMsg) + print("\n\n----------------------------\nProgram ABORTED Due to Unexpected TAOS Error: \n\n{}\n".format(errMsg) +
"----------------------------\n") "----------------------------\n")
# sys.exit(-1) # sys.exit(-1)