[Python-ideas] async/await in Python

Nicholas Chammas nicholas.chammas at gmail.com
Sun Apr 19 21:35:20 CEST 2015


Is Mike Bayer
<http://techspot.zzzeek.org/2015/02/15/asynchronous-python-and-databases/>
on this list? Just curious as a n00b observer if he has thoughts on this
new PEP, since we are talking about SQLAlchemy.

Nick

On Sun, Apr 19, 2015 at 3:30 PM Yury Selivanov <yselivanov.ml at gmail.com>
wrote:

> Hi Antoine,
>
> On 2015-04-19 3:23 PM, Antoine Pitrou wrote:
> > On Sun, 19 Apr 2015 15:06:31 -0400
> > Yury Selivanov <yselivanov.ml at gmail.com>
> > wrote:
> >> Hi Antonie,
> > (OT: It's Antoine, not "Antonie")
> I apologize for misspelling your name.  Sorry.
>
>
> Anyways, my only intent when I was replying to your last
> email was to show you, that it is possible to develop
> an ORM where queries do not occur at random places
> because of __getattr__/iteration.
>
> If you want to have ORM and asyncio and avoid using
> greenlets, then you have several problems to solve:
>
> 1. Queries in getattr -- that's possible it you always
> describe the shape of data you want.  If you later
> access some attribute that wasn't fetched -- you get
> an error.
>
> 2. Sane syntax for transaction managers, session
> managers and connection pools.  Of course you can
> use 'yield from', 'try' and 'finally' right now.
>
> 3. San syntax for iteration.  You can use 'while True'
> but it's not elegant.
>
> Thank you,
> Yury
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
> Code of Conduct: http://python.org/psf/codeofconduct/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20150419/6dda65e7/attachment.html>


More information about the Python-ideas mailing list