bpo-33649: Add a high-level section about Futures; few quick fixes#9403
bpo-33649: Add a high-level section about Futures; few quick fixes#94031st1 merged 10 commits intopython:masterfrom
Conversation
Doc/library/asyncio-task.rst
Outdated
| with regards to cancellation and introspection. | ||
|
|
||
| Many asyncio APIs are documented to accept coroutines, Tasks, or | ||
| Futures. What it means is that they are ready to accept anything |
There was a problem hiding this comment.
By doing so, the async APIs are ready to accept anything which you can await on.
Doc/library/asyncio-task.rst
Outdated
|
|
||
| Return a Future aggregating results from the given coroutine objects, | ||
| Tasks, or Futures. | ||
| Return a :class:`Future` aggregating results from the given |
There was a problem hiding this comment.
*fs is used in this section without any prior mention on the page. We should have a brief verbal description here.
|
@willingc Carol, I decided to introduce awaitables and use them to simplify (hopefully!) the docs. Please take another look. |
willingc
left a comment
There was a problem hiding this comment.
I love it! I think awaitables will simplify understanding a bit. Then, we can work toward high level guidance on what is Task, Future, Coroutine are and when to consider using. ![]()
|
Great suggestion @elprans re: *fs sequence 👍 |
|
Thanks @1st1 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7. |
…ythonGH-9403) Co-authored-by: Elvis Pranskevichus <elvis@magic.io> (cherry picked from commit 4715039) Co-authored-by: Yury Selivanov <yury@magic.io>
|
GH-9409 is a backport of this pull request to the 3.7 branch. |
https://bugs.python.org/issue33649