[PyQt] Re: PyQt4 QTableWidget crashed/hang when sorting

nEO (a.k.a. gentoo.cn) gentoo.cn at gmail.com
Fri Sep 14 14:29:22 BST 2007

On 9/14/07, nEO (a.k.a. gentoo.cn) <gentoo.cn at gmail.com> wrote:
> Platform:
>     Win32  PyQt4.3.0-GPL  with Qt-4.3.1-opensource,  Python 2.5
> Symptoms:
>     QTableWiget sort by a long string column, after remove some rows,
> then sort again will deak lock or crashed.  Sometimes can got a msg
> from console:
>     "Qt has caught an exception thrown from an event handler. Throwing
> exceptions from an event handler is not supported in Qt. You must
> reimplement QApplication::notify() and catch all exceptions there."
> Test Program:
>    see attachment: testTbw.py
> Usage:
>    run testTbw.py   and click some cell wait a while program will crashed.
> Maybe it's caused by a GC problem or TableWidget's model r/w competition.
> Anyone can help me find root cause and how to fix it?

I have excluded Qt's problem. I wrote a C++ version of this test program.
It's run ok.
C++ version test program source is attached as attachments.
run in CMD:
qmake testTbw.pro
cd release

And I run python version test program under PyQt4.3 with Qt 4.2.3 in Linux,
It's seem no problem too.

I'm the one, powered by nEO
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testTbw.cpp
Type: application/octet-stream
Size: 2594 bytes
Desc: not available
Url : http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20070914/38974c90/testTbw.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testTbw.h
Type: application/octet-stream
Size: 650 bytes
Desc: not available
Url : http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20070914/38974c90/testTbw-0001.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testTbw.pro
Type: application/octet-stream
Size: 212 bytes
Desc: not available
Url : http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20070914/38974c90/testTbw-0002.obj

More information about the PyQt mailing list