Port obmc.mapper to python3.5
Change-Id: I472d92ddae72f004fb9d00103f160c9b108143fd
Signed-off-by: Balaji B Rao <balajibapu@gmail.com>
diff --git a/obmc/mapper/utils.py b/obmc/mapper/utils.py
index 3937cf6..6f1b6b6 100644
--- a/obmc/mapper/utils.py
+++ b/obmc/mapper/utils.py
@@ -24,7 +24,7 @@
class Wait(object):
def __init__(self, bus, waitlist, *a, **kw):
self.bus = bus
- self.waitlist = dict(zip(waitlist, [None]*len(waitlist)))
+ self.waitlist = dict(list(zip(waitlist, [None]*len(waitlist))))
mapper = bus.get_object(
obmc.mapper.MAPPER_NAME,
obmc.mapper.MAPPER_PATH,
@@ -121,6 +121,5 @@
if self.done:
return
- for path in filter(
- lambda x: not self.waitlist[x], self.waitlist.keys()):
+ for path in [x for x in list(self.waitlist.keys()) if not self.waitlist[x]]:
self.get_object_async(path, 0)