From 43f19cc94b9e6e90111ff153422da2b2a104f379 Mon Sep 17 00:00:00 2001 From: Ryan Petrello Date: Thu, 18 Jan 2018 13:17:06 -0500 Subject: [PATCH] fix another bug that breaks the JT callback process see: https://github.com/ansible/awx/issues/980 related: 17cd0595d70056b214db851952486ae2746f2c6c --- awx/api/views.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/awx/api/views.py b/awx/api/views.py index bd00d05009..f95ae3a153 100644 --- a/awx/api/views.py +++ b/awx/api/views.py @@ -3285,7 +3285,9 @@ class JobTemplateCallback(GenericAPIView): for inventory_source in inventory_sources: if inventory_source.needs_update_on_launch: # FIXME: Doesn't check for any existing updates. - inventory_update = inventory_source.create_inventory_update(launch_type='callback') + inventory_update = inventory_source.create_inventory_update( + **{'_eager_fields': {'launch_type': 'callback'}} + ) inventory_update.signal_start() inventory_update_pks.add(inventory_update.pk) inventory_update_qs = InventoryUpdate.objects.filter(pk__in=inventory_update_pks, status__in=('pending', 'waiting', 'running'))