diff --git a/setup.py b/setup.py index d6a401a..3ca26c3 100644 --- a/setup.py +++ b/setup.py @@ -27,8 +27,8 @@ 'Topic :: Software Development :: Libraries :: Python Modules', ], install_requires=[ - 'async-timeout>=3.0.1', - 'bitstring>=3.1.5', - 'pyserial-asyncio>=0.4', + 'async-timeout>=4.0', + 'bitstring>=3.1', + 'pyserial-asyncio>=0.6', ], ) diff --git a/sml/asyncio.py b/sml/asyncio.py index 36ca7c4..3835e1a 100644 --- a/sml/asyncio.py +++ b/sml/asyncio.py @@ -104,7 +104,7 @@ async def _reconnect(self, delay: int = 10): await self._disconnect() await asyncio.sleep(delay, loop=self._loop) try: - async with timeout(5, loop=self._loop): + async with timeout(5): self._transport, _ = await self._create_connection() except (BrokenPipeError, ConnectionRefusedError, SerialException, asyncio.TimeoutError) as exc: