RuntimeWarning: tp_compare

Bruno Barberi Gnecco brunobgDELETETHIS at users.sourceforge.net
Tue Oct 9 16:55:49 EDT 2007


	I'm getting the following exception when I call an external extension
(pytst):

/usr/lib/python2.5/threading.py:697: RuntimeWarning: tp_compare didn't return -1 or -2 for 
exception
   return _active[_get_ident()]
Traceback (most recent call last):
   File "testDataMiner2.py", line 77, in <module>
     testPlace()
   File "testDataMiner2.py", line 41, in testPlace
     data = db.getDescription(event['id'])
   File "testDataMiner2.py", line 28, in getDescription
     return self.getRow(query, (id,))
   File "../database.py", line 73, in getRow
     self.readlock.acquire()
   File "/usr/lib/python2.5/threading.py", line 94, in acquire
     me = currentThread()
   File "/usr/lib/python2.5/threading.py", line 697, in currentThread
     return _active[_get_ident()]
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfa' in position 52: ordinal 
not in range(128)
awer
 > /usr/lib/python2.5/threading.py(700)currentThread()
-> return _DummyThread()


	Note that the error occurs *after* the call that I isolated as
affecting it (pytst.scan(), in the case). This doesn't happen for simple,
isolated cases, but googling for "tp_compare threading" shows a lot of
similar issues. Does anybody here know what this could be about? Any ideas
to debug or work around it?

-- 
Bruno Barberi Gnecco <brunobg_at_users.sourceforge.net>
I can read your mind, and you should be ashamed of yourself.



More information about the Python-list mailing list