diff --git a/src/cozmo/event.py b/src/cozmo/event.py index 4917f36b..a277189b 100644 --- a/src/cozmo/event.py +++ b/src/cozmo/event.py @@ -485,7 +485,7 @@ async def wait_for(self, event_or_filter, timeout=30): self.add_event_handler(event, f) if timeout: - return await asyncio.wait_for(f, timeout, loop=self._loop) + return await asyncio.wait_for(f, timeout) return await f diff --git a/src/cozmo/run.py b/src/cozmo/run.py index 673101a2..440aa738 100644 --- a/src/cozmo/run.py +++ b/src/cozmo/run.py @@ -361,7 +361,7 @@ def __init__(self): async def _do_connect(self, connector,loop, protocol_factory, conn_check): connect = connector.connect(loop, protocol_factory, conn_check) - result = await asyncio.gather(connect, loop=loop, return_exceptions=True) + result = await asyncio.gather(connect, return_exceptions=True) return result[0] async def connect(self, loop, protocol_factory, conn_check):