git://git.onelab.eu
/
plstackapi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f93c26b
)
If an object's peer is not set, it implies no dependency. So rather than
author
Sapan Bhatia
<gwsapan@gmail.com>
Mon, 4 Aug 2014 14:48:28 +0000
(10:48 -0400)
committer
Sapan Bhatia
<gwsapan@gmail.com>
Mon, 4 Aug 2014 14:48:28 +0000
(10:48 -0400)
failing the dependency check, we pass it.
planetstack/ec2_observer/syncstep.py
patch
|
blob
|
history
diff --git
a/planetstack/ec2_observer/syncstep.py
b/planetstack/ec2_observer/syncstep.py
index
dcfea7d
..
d5f7523
100644
(file)
--- a/
planetstack/ec2_observer/syncstep.py
+++ b/
planetstack/ec2_observer/syncstep.py
@@
-60,7
+60,10
@@
class SyncStep:
for dep in self.dependencies:
peer_name = dep[0].lower() + dep[1:] # django names are camelCased with the first letter lower
peer_object = getattr(obj, peer_name)
- if (peer_object.pk==failed.pk):
+
+ # peer_object can be None, and if so there
+ # is no object-level dependency
+ if (peer_object and peer_object.pk==failed.pk):
raise FailedDependency
def call(self, failed=[], deletion=False):