Steps in which deletion is not supported have to return an empty list
when queried for deleted objects.
diff --git a/planetstack/openstack_observer/steps/sync_roles.py b/planetstack/openstack_observer/steps/sync_roles.py
index e3a20e9..bb837db 100644
--- a/planetstack/openstack_observer/steps/sync_roles.py
+++ b/planetstack/openstack_observer/steps/sync_roles.py
@@ -11,7 +11,11 @@
provides=[Role]
requested_interval=0
- def fetch_pending(self):
+ def fetch_pending(self, deleted):
+ # Deleting roles is not supported yet
+ if (deleted):
+ return []
+
site_roles = SiteRole.objects.filter(Q(enacted__lt=F('updated')) | Q(enacted=None))
slice_roles = SliceRole.objects.filter(Q(enacted__lt=F('updated')) | Q(enacted=None))
deployment_roles = DeploymentRole.objects.filter(Q(enacted__lt=F('updated')) | Q(enacted=None))