logo       
Google Custom Search
    AddThis Social Bookmark Button
-->

Re: [psycopg] #7: Using dictfetchone on a cursor that has not been executed: msg#00041

Subject: Re: [psycopg] #7: Using dictfetchone on a cursor that has not been executed makes Python core dump.
#7: Using dictfetchone on a cursor that has not been executed makes Python core
dump.
----------------------+-----------------------------------------------------
       Id:  7         |      Status:  assigned                        
Component:  psycopg1  |    Modified:  Fri 15 Apr 2005 01:16:29 PM CEST
 Severity:  normal    |   Milestone:                                  
 Priority:  normal    |     Version:  1.1.18                          
    Owner:  fog       |    Reporter:  mrb                             
----------------------+-----------------------------------------------------
Changes (by kev at logicalprogression dot nospam dot net):

  * keywords:  => segfault dictfetchone
  * cc:  => kev@xxxxxxxxxxxxxxxxxxxxxx

Comment:

 The issue also seems to occur if doing fetchone on a query which doesn't
 return any values, eg: an INSERT. fetchone() will raise an exception, as
 per the traceback below. dictfetchone() will segfault instead.

   File "/home/kev/pgperftest.py", line 130, in runtest
     data = dbcursor.fetchone()
 psycopg.Error: no results to fetch

-- 
Ticket URL: <http://initd.org/tracker/psycopg/ticket/7>
psycopg <http://initd.org/>
psycopg
_______________________________________________
Psycopg mailing list
Psycopg-IAPFreCvJWPBWskQ1e/+sw@xxxxxxxxxxxxxxxx
http://lists.initd.org/mailman/listinfo/psycopg
<Prev in Thread] Current Thread [Next in Thread>