Re: Async support in psycopg2

Nathan <[email protected]>
Newsgroups gmane.comp.python.db.psycopg.devel
Message-ID <[email protected]>
On Thu, Oct 1, 2009 at 3:26 PM, Dustin Spicuzza
<dustin-Jt2G5/[email protected]> wrote:
> Federico Di Gregorio wrote:
>> Il giorno mer, 30/09/2009 alle 20.32 -0400, Dustin Spicuzza ha scritto:
>>> Hey,
>>>
>>> I'm using psycopg2 on Ubuntu 9.04, and it looks like the documentation
>>> and implementation for the asynchronous interface is lacking quite a bit:
>>>
>>>  - the cursor does not have an "isbusy()", it is actually called "isready()"
>>>  - the cursor does not have a cancel() either -- and a grep of the
>>> sources in git shows that the word cancel appears nowhere in the
>>> sources.... so how exactly does one cancel a query?
>>
>> Asynchronous support is only half-backed. Nobody really helped testing
>> it and I don't use psycopg in a way that requires async queries anymore
>> (mostly I use psycopg in short python scripts for administrative tasks.)
>>
>> So, don't expect it to work.
>>
>
> Fair enough. Could you at least update the documentation then to note
> that it doesn't work? Will save someone some time in the future.
>
> Dustin

FYI, you can use Twisted ( http://twistedmatrix.com/trac/ ) with
psycopg as the DB module if you _just_ want asynchronous access to
your database -- though you'll need to learn twisted and do things the
twisted way.

~ Nathan
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.