On Tue, Aug 29, 2017 at 12:59 PM, Yury Selivanov <yselivanov.ml at gmail.com> wrote: > b2 = wait_for(bar()) > # bar() was wrapped into a Task and is being running right now > await b2 Ah.... not quite. wait_for is itself implemented as a coroutine, so it doesn't spawn off bar() into its own task until you await b2. Though according to the docs you should pretend that you don't know whether wait_for returns a coroutine or a Future, so what you said would also be a conforming implementation. -n -- Nathaniel J. Smith -- https://vorpus.org
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4