mirror of
https://github.com/ansible/awx.git
synced 2026-05-12 11:57:37 -02:30
always log uncaught task exceptions
This commit is contained in:
@@ -1000,10 +1000,10 @@ class BaseTask(Task):
|
|||||||
)
|
)
|
||||||
|
|
||||||
except Exception:
|
except Exception:
|
||||||
if status != 'canceled':
|
# run_pexpect does not throw exceptions for cancel or timeout
|
||||||
tb = traceback.format_exc()
|
# this could catch programming or file system errors
|
||||||
if settings.DEBUG:
|
tb = traceback.format_exc()
|
||||||
logger.exception('%s Exception occurred while running task', instance.log_format)
|
logger.exception('%s Exception occurred while running task', instance.log_format)
|
||||||
finally:
|
finally:
|
||||||
try:
|
try:
|
||||||
if stdout_handle:
|
if stdout_handle:
|
||||||
|
|||||||
Reference in New Issue
Block a user