[New-bugs-announce] [issue36806] Forbid creating of stream objects outside of asyncio

Andrew Svetlov report at bugs.python.org
Sun May 5 15:15:37 EDT 2019


New submission from Andrew Svetlov <andrew.svetlov at gmail.com>:

They were intended to be used by asyncio factories like open_connection from the very beginning but internals was leaked into asyncio top-level namespace.

The idea is: 
1. provide `_asyncio_internal` keyword-only parameter to leaked classes constructor 
2. have it False by default
3. Use `_asyncio_internal=True` when called from asyncio code.
3. Raise DeprecationWarning if `_asyncio_internal` is False

----------
components: asyncio
messages: 341472
nosy: asvetlov, yselivanov
priority: normal
severity: normal
status: open
title: Forbid creating of stream objects outside of asyncio
versions: Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue36806>
_______________________________________


More information about the New-bugs-announce mailing list