async enumeration - possible?

Peter Otten __peter__ at web.de
Wed Nov 30 04:27:53 EST 2016


Steve D'Aprano wrote:

> On Wed, 30 Nov 2016 07:07 am, Marko Rauhamaa wrote:
> 
>> Terry Reedy <tjreedy at udel.edu>:
>> 
>>> On 11/29/2016 9:25 AM, Frank Millman wrote:
>>>
>>>> Is there any technical reason for this, or is it just that no-one has
>>>> got around to writing an asynchronous version yet?
>>>
>>> Google's first hit for 'aenumerate' is
>>>
> https://pythonwise.blogspot.com/2015/11/aenumerate-enumerate-for-async-for.html
>> 
>> Ok, so how about:
>> 
>>    aall(aiterable)
>>    aany(aiterable)
>>    class abytearray(aiterable[, encoding[, errors]])
> [...]
> 
> 
> What about them? What's your question?

Well, my questions as someone who hasn't touched the async stuff so far 
would be:

Is there a viable approach to provide

(a) support for async without duplicating the stdlib
(b) a reasonably elegant way to access the async versions

I hope we can agree that prepending an "a" to the name should be the last 
resort.




More information about the Python-list mailing list