do not cache dependency_list

* This is probably causing some bug. Calls to start_task within the same
run of the task manager could result in previous dependency lists being
used.
This commit is contained in:
chris meyers 2018-05-29 10:27:51 -04:00
parent 0fca495792
commit 4da68564ef

View File

@ -234,9 +234,11 @@ class TaskManager():
def get_dependent_jobs_for_inv_and_proj_update(self, job_obj):
return [{'type': j.model_to_str(), 'id': j.id} for j in job_obj.dependent_jobs.all()]
def start_task(self, task, rampart_group, dependent_tasks=[]):
def start_task(self, task, rampart_group, dependent_tasks=None):
from awx.main.tasks import handle_work_error, handle_work_success
dependent_tasks = dependent_tasks or []
task_actual = {
'type': get_type_for_model(type(task)),
'id': task.id,