You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 23, 2017. It is now read-only.
debug = False results in: __await__() returned a coroutine
debug = True results in: Foo
This behaviour was indeed surprising when I begun to work and experiment with asyncio, where most of the time I enabled debug, but in unit testing then disabled it...
I am wondering, if the TypeError for a coroutine returned by await() enforced by https://www.python.org/dev/peps/pep-0492/#await-expression is really necessary. Btw to use await syntax in await I always return the result of the await method of an inner coroutine, e.g.:
My python version is 3.5.2
The following example illustrates the problem:
This behaviour was indeed surprising when I begun to work and experiment with asyncio, where most of the time I enabled debug, but in unit testing then disabled it...
I am wondering, if the TypeError for a coroutine returned by await() enforced by https://www.python.org/dev/peps/pep-0492/#await-expression is really necessary. Btw to use await syntax in await I always return the result of the await method of an inner coroutine, e.g.: