Skip to content

Commit f4dbfb7

Browse files
sobolevnAA-Turner
authored andcommitted
pythongh-114281: Remove incorrect type hints from asyncio.staggered (python#114282)
Co-authored-by: Adam Turner <[email protected]>
1 parent 600f0c0 commit f4dbfb7

File tree

2 files changed

+4
-11
lines changed

2 files changed

+4
-11
lines changed

Lib/asyncio/staggered.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,14 @@
33
__all__ = 'staggered_race',
44

55
import contextlib
6-
import typing
76

87
from . import events
98
from . import exceptions as exceptions_mod
109
from . import locks
1110
from . import tasks
1211

1312

14-
async def staggered_race(
15-
coro_fns: typing.Iterable[typing.Callable[[], typing.Awaitable]],
16-
delay: typing.Optional[float],
17-
*,
18-
loop: events.AbstractEventLoop = None,
19-
) -> typing.Tuple[
20-
typing.Any,
21-
typing.Optional[int],
22-
typing.List[typing.Optional[Exception]]
23-
]:
13+
async def staggered_race(coro_fns, delay, *, loop=None):
2414
"""Run coroutines with staggered start times and take the first to finish.
2515
2616
This method takes an iterable of coroutine functions. The first one is
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Remove type hints from ``Lib/asyncio/staggered.py``.
2+
The annotations in the `typeshed <https://github.com/python/typeshed>`__
3+
project should be used instead.

0 commit comments

Comments
 (0)