New submission from Олег Иванов:

Docs claims there there is asyncio.ensure_future

https://docs.python.org/3/library/asyncio-task.html?highlight=ensure_future#asyncio.ensure_future

but example from docs does'nt work:

import asyncio

loop = asyncio.get_event_loop()
tasks = [
    asyncio.ensure_future(print("asasda")),

]
loop.run_until_complete(asyncio.wait(tasks))
loop.close()

Fails with:

AttributeError: 'module' object has no attribute 'ensure_future'

----------
assignee: docs@python
components: Documentation
messages: 245176
nosy: docs@python, Олег Иванов
priority: normal
severity: normal
status: open
title: There is no asyncio.ensure_future in Python 3.4.3
type: behavior
versions: Python 3.4

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue24433>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to