On Tue, Nov 12, 2013 at 7:41 PM, M.-A. Lemburg wrote:
> On 11.11.2013 10:43, INADA Naoki wrote:
> > I think having definition about what method returns Future is good.
> >
> > For example:
> >
> > con = yield from pymysql.connect_async(...) # connection may cause
> > cur = con.cursor() # cursor
On 11.11.2013 10:43, INADA Naoki wrote:
> I think having definition about what method returns Future is good.
>
> For example:
>
> con = yield from pymysql.connect_async(...) # connection may cause
> cur = con.cursor() # cursor creation should done without asyncio
> yield from cur.execute("..."
On Nov 12, 2013, at 9:51 AM, M.-A. Lemburg wrote:
>
> For mxODBC Connect, we've implemented gevent compatibility,
> so you can use async processing without having to change
> your code - which IMHO is the nicest way to do async
> processing :-)
though sadly just doesn’t seem to be catching on,
On 12.11.2013 12:03, INADA Naoki wrote:
> On Tue, Nov 12, 2013 at 7:41 PM, M.-A. Lemburg wrote:
>
>> On 11.11.2013 10:43, INADA Naoki wrote:
>>> I think having definition about what method returns Future is good.
>>>
>>> For example:
>>>
>>> con = yield from pymysql.connect_async(...) # connecti
I think having definition about what method returns Future is good.
For example:
con = yield from pymysql.connect_async(...) # connection may cause
cur = con.cursor() # cursor creation should done without asyncio
yield from cur.execute("...") # execute may use asyncio
row = yield from cur.fetc
What sort of thing do you have in mind? Perhaps something where the
execute() method returns immediately, and a callback function is called
when the query is complete?
This could be implemented in a library on top of DB-API. But should it be
part of the spec?
Cheers,
Tony.
On 25 October 2013 0
Does someone consider DB-API for asyncio?
--
INADA Naoki
___
DB-SIG maillist - DB-SIG@python.org
https://mail.python.org/mailman/listinfo/db-sig