Author xtreak
Recipients asvetlov, stuball123, xtreak, yselivanov
Date 2020-02-13.09:03:31
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1581584611.36.0.520842064597.issue39623@roundup.psfhosted.org>
In-reply-to
Content
This could sometimes make the output verbose when the arguments themselves are tasks while including arguments in the signature in _format_coroutine.

$ cat /tmp/foo.py
import asyncio

async def foo(a, b): pass

async def main():
    task = asyncio.create_task(foo(1, b=1))
    task1 = asyncio.create_task(foo(1, b=task))
    print(repr(task))
    print(repr(task1))

asyncio.run(main())

$ python3.8 /tmp/foo.py
<Task pending name='Task-2' coro=<foo() running at /tmp/foo.py:3>>
<Task pending name='Task-3' coro=<foo() running at /tmp/foo.py:3>>

$ ./python.exe /tmp/foo.py
<Task pending name='Task-2' coro=<foo(a=1, b=1) running at /tmp/foo.py:3>>
<Task pending name='Task-3' coro=<foo(a=1, b=<Task pending name='Task-2' coro=<foo(a=1, b=1) running at /tmp/foo.py:3>>) running at /tmp/foo.py:3>>
History
Date User Action Args
2020-02-13 09:03:31xtreaksetrecipients: + xtreak, asvetlov, yselivanov, stuball123
2020-02-13 09:03:31xtreaksetmessageid: <1581584611.36.0.520842064597.issue39623@roundup.psfhosted.org>
2020-02-13 09:03:31xtreaklinkissue39623 messages
2020-02-13 09:03:31xtreakcreate