[PyQt] Possible bug: Instantiating QWebPage results in segfault

Ken Kinder kkinder at gmail.com
Fri Mar 8 03:28:12 GMT 2013


On 03/02/2013 01:54 AM, Phil Thompson wrote:
> Qt has its on internal, undocumented (and probably version dependent)
> requirements about the order in which C++ dtors are called. The Python
> garbage collector does not destroy objects in any predictable order.
> From time to time the two clash. Apart from deleteLater() you could
> explicitly del the QWebPage instance, or give it a parent, or call
> sip.setdestroyonexit(False) somewhere in your code. The latter will
> probably be the default in PyQt5. Phil 

Ah, I figured it out. So basically the thing is that I need to call
deleteLater() at the time I'm done with the object. Thanks for the
(fast!) reply.

-Ken



More information about the PyQt mailing list