diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2014-06-16 22:26:36 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2014-06-16 22:26:36 (GMT) |
commit | bc434e205261fbe9afc45f5f601d2238ffbe09f9 (patch) | |
tree | bf8a91677b58824d5b40e987c1f6f8cb4082e53f | |
parent | 4b0432d1908424a9c6d471f0f31e9c9e3d5d97af (diff) | |
download | cpython-bc434e205261fbe9afc45f5f601d2238ffbe09f9.zip cpython-bc434e205261fbe9afc45f5f601d2238ffbe09f9.tar.gz cpython-bc434e205261fbe9afc45f5f601d2238ffbe09f9.tar.bz2 |
asyncio: Task.__repr__() now also handles CoroWrapper
-rw-r--r-- | Lib/asyncio/tasks.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/asyncio/tasks.py b/Lib/asyncio/tasks.py index e6fd3d3..281bf60 100644 --- a/Lib/asyncio/tasks.py +++ b/Lib/asyncio/tasks.py @@ -190,7 +190,7 @@ class Task(futures.Future): i = len(res) text = self._coro.__name__ coro = self._coro - if inspect.isgenerator(coro): + if iscoroutine(coro): filename = coro.gi_code.co_filename if coro.gi_frame is not None: text += ' at %s:%s' % (filename, coro.gi_frame.f_lineno) |