[New-bugs-announce] [issue30098] Verbose TypeError for asyncio.ensure_future

crenwick report at bugs.python.org
Tue Apr 18 18:24:34 EDT 2017


New submission from crenwick:

Despite the shy mention in the docs, it was not clear to me that the future returned from asyncio.run_coroutine_threadsafe is not compatible with asyncio.ensure_future (and other asyncio functions), and it took me a fair amount of frustration and source-code-digging to figure out what was going on.

To avoid this confusion for other users, I think that a verbose TypeError warning when a concurrent.futures.Future object is passed into asyncio.ensure_future would be very helpful.

----------
components: asyncio
messages: 291845
nosy: crenwick, yselivanov
priority: normal
pull_requests: 1302
severity: normal
status: open
title: Verbose TypeError for asyncio.ensure_future
type: enhancement
versions: Python 3.7

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue30098>
_______________________________________


More information about the New-bugs-announce mailing list