Skip to content

Commit 2870219

Browse files
authored
Stop using loop kwarg in asyncio.wait() call (DeprecationWarning) (#327)
1 parent 9bc4a20 commit 2870219

2 files changed

Lines changed: 4 additions & 5 deletions

File tree

uvloop/handles/process.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,7 @@ cdef class UVProcessTransport(UVProcess):
604604

605605
if handle._init_futs:
606606
handle._stdio_ready = 0
607-
init_fut = aio_gather(*handle._init_futs, loop=loop)
607+
init_fut = aio_gather(*handle._init_futs)
608608
init_fut.add_done_callback(
609609
ft_partial(handle.__stdio_inited, waiter))
610610
else:

uvloop/loop.pyx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1682,7 +1682,7 @@ cdef class Loop:
16821682
uv.SOCK_STREAM, 0, flags,
16831683
0) for host in hosts]
16841684

1685-
infos = await aio_gather(*fs, loop=self)
1685+
infos = await aio_gather(*fs)
16861686

16871687
completed = False
16881688
sock = None
@@ -1908,7 +1908,7 @@ cdef class Loop:
19081908
lai = &lai_static
19091909

19101910
if len(fs):
1911-
await aio_wait(fs, loop=self)
1911+
await aio_wait(fs)
19121912

19131913
if rai is NULL:
19141914
ai_remote = f1.result()
@@ -3095,8 +3095,7 @@ cdef class Loop:
30953095

30963096
shutdown_coro = aio_gather(
30973097
*[ag.aclose() for ag in closing_agens],
3098-
return_exceptions=True,
3099-
loop=self)
3098+
return_exceptions=True)
31003099

31013100
results = await shutdown_coro
31023101
for result, agen in zip(results, closing_agens):

0 commit comments

Comments
 (0)