[PyKDE] Simple KHtml program crashing at exit

Jim Bublitz jbublitz at nwinternet.com
Thu Aug 11 18:23:51 BST 2005


On Thursday 11 August 2005 10:03, David Boddie wrote:
>  looked at some of my own experiments with using KHTML from
> ython, and found that you can at least stop the crash on exit by
> mplementing a close method:
>
>    def close(self, alsoDelete = 1):
>        return HWidget.close(self, 1)
>
> ote that it forces the deletion of the widget whether it was
> equested or not. Clearly, it's not a good idea to try and use the
> idget after this has been called.
>
> o, I expect there may be an issue with object ownership somewhere.
>
> avid

(Somehow I received this with the  leftmost characters missing on every line - 
data compression?)

There was/is a problem with deletion order with C++ objects and Python objects 
wrapping them - I don't recall all of the details (some handwritten code was 
required though), but should probably take a look at it again. It's possible 
sip has changed in some way that affects this and I haven't updated for that.

Implementing the slots associated with closing and querying to close the main 
window/application seems to work though.

Jim




More information about the PyQt mailing list