Skip to content

Commit

Permalink
Fix asyncio.run() docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
aeros committed Sep 25, 2019
1 parent 78bf148 commit 8af372a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Lib/asyncio/runners.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@ def run(main, *, debug=False):
It should be used as a main entry point for asyncio programs, and should
ideally only be called once.
Return a result of *coro* execution, or raise a RuntimeError
if `asyncio.run()`is called from a running event loop, or a ValueError
if `main` is not a courutine.
Within the new event loop, *coro* is executed, returning the result. If
``asyncio.run()`` is called within a running event loop, a
:exc:`RuntimeError` is raised. If *coro* is not a :term:`coroutine`, a
:exc:`ValueError` is raised.
Example:
Expand Down

0 comments on commit 8af372a

Please sign in to comment.