Skip to content

Commit

Permalink
Merge pull request #679 from adiroiban/patch-1
Browse files Browse the repository at this point in the history
Update trio example to work with latest trio
  • Loading branch information
PierreF authored Dec 28, 2023
2 parents 0f6ba1b + abc9c33 commit 24fd02d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/loop_trio.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ def __init__(self, client):

async def read_loop(self):
while True:
await trio.hazmat.wait_readable(self.sock)
await trio.lowlevel.wait_readable(self.sock)
self.client.loop_read()

async def write_loop(self):
while True:
await self._event_large_write.wait()
await trio.hazmat.wait_writable(self.sock)
await trio.lowlevel.wait_writable(self.sock)
self.client.loop_write()

async def misc_loop(self):
Expand Down

0 comments on commit 24fd02d

Please sign in to comment.