mirror of
https://github.com/ansible/awx.git
synced 2026-01-12 10:30:03 -03:30
handle_work_error signature to work
* celery error callback signature isn't well defined. Thus, our error callback signature is made to handle just about any call signature and depend on only 1 attribute, id, existing. See https://github.com/celery/celery/issues/3709
This commit is contained in:
parent
815cd829e0
commit
f0ff6ecb0a
@ -363,8 +363,9 @@ def handle_work_success(self, result, task_actual):
|
||||
|
||||
|
||||
@shared_task(queue='tower', base=LogErrorsTask)
|
||||
def handle_work_error(request, exc, traceback, task_id, subtasks=None):
|
||||
logger.debug('Executing error task id %s, subtasks: %s' % (request.id, str(subtasks)))
|
||||
def handle_work_error(task_id, *args, **kwargs):
|
||||
subtasks = kwargs.get('subtasks', None)
|
||||
logger.debug('Executing error task id %s, subtasks: %s' % (task_id, str(subtasks)))
|
||||
first_instance = None
|
||||
first_instance_type = ''
|
||||
if subtasks is not None:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user