New submission from Andrew Svetlov <andrew.svet...@gmail.com>:

Now constructions like

await lock  # "yield from lock" can be used as well
try:
    ...
finally:
    lock.release()

and

with (yield from lock):
    ...

are supported. Let's deprecate them in favor of

async with lock:
    ...

----------
components: asyncio
messages: 307839
nosy: asvetlov, yselivanov
priority: normal
severity: normal
status: open
title: Deprecate old-style locking in asyncio/locks.py
versions: Python 3.7

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

Reply via email to