Skip to content

Commit 8401387

Browse files
bdracoaequitas
authored andcommitted
Drop a few more loop arguments
Fixes #67
1 parent ddf4b91 commit 8401387

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

rflink/protocol.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -232,8 +232,8 @@ def __init__(
232232
super().__init__(*args, **kwargs)
233233
if packet_callback:
234234
self.packet_callback = packet_callback
235-
self._command_ack = asyncio.Event(loop=self.loop)
236-
self._ready_to_send = asyncio.Lock(loop=self.loop)
235+
self._command_ack = asyncio.Event()
236+
self._ready_to_send = asyncio.Lock()
237237

238238
def handle_response_packet(self, packet: PacketType) -> None:
239239
"""Handle response packet."""
@@ -254,9 +254,7 @@ def send_command_ack(
254254

255255
log.debug("waiting for acknowledgement")
256256
try:
257-
yield from asyncio.wait_for(
258-
self._command_ack.wait(), TIMEOUT.seconds, loop=self.loop
259-
)
257+
yield from asyncio.wait_for(self._command_ack.wait(), TIMEOUT.seconds)
260258
log.debug("packet acknowledged")
261259
except concurrent.futures._base.TimeoutError:
262260
acknowledgement = False

0 commit comments

Comments
 (0)