[Python-ideas] async/await in Python

Mark Lawrence breamoreboy at yahoo.co.uk
Sat Apr 18 04:26:49 CEST 2015


On 18/04/2015 02:31, Dan O'Reilly wrote:
>
> This is exciting! I expect this will eliminate some of the confusion I
> see from new users of asyncio on StackOverflow.
>
> I'm curious about what this means for asyncio best practices from 3.5
> onward, though. Is the use of @asyncio.coroutine/yield from being
> deprecated in asyncio once this feature is added? I guess anyone that
> needs to write backwards compatible code would need to continue using
> the old way, so perhaps not yet? At the very least the docs should
> probably mention that the async/wait syntax is available/preferred for
> code that only needs to support 3.5+. If you're going the deprecation
> route, the docs should be updated to use async/await, and probably just
> include a note stating that the old @asyncio.coroutine/yield from method
> is required to support 3.4 and lower.
>

Would people please be kind enough to hold their horses?  I'm getting 
the impression that this is expected in 3.5, but according to PEP 478 
beta 1 is due on 24th May 2015, so it looks as if somebody has got to 
get their skates on.  Or have I (as usual) missed something, in which 
case I'll apologise now, mainly because it's Saturday 18/04/2015 03:26 
BST and I'm heading off to bed.  Good night all :)

-- 
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence



More information about the Python-ideas mailing list