fix failing to return an ip if sliver.ip is not set
authorScott Baker <smbaker@gmail.com>
Wed, 20 Aug 2014 19:33:26 +0000 (12:33 -0700)
committerScott Baker <smbaker@gmail.com>
Wed, 20 Aug 2014 19:33:26 +0000 (12:33 -0700)
planetstack/tools/get_instance_ip.py

index 69c6af5..c227e2e 100644 (file)
@@ -59,7 +59,7 @@ def main():
 
     # get (instance_name, ip) pairs for instances with names and ips
 
-    slivers = [x for x in slivers if x["instance_name"] and x["ip"]]
+    slivers = [x for x in slivers if x["instance_name"]]
     slivers = sorted(slivers, key = lambda sliver: sliver["instance_name"])
 
     # return the last one in the list (i.e. the newest one)