[PyQt] pyqtSlot decorator

Iosif Spulber iosif.spulber at gmail.com
Thu Sep 24 14:33:23 BST 2015


I had a similar question which includes some of these weird corner cases:
https://www.riverbankcomputing.com/pipermail/pyqt/2015-August/036287.html


On Thu, Sep 24, 2015 at 2:16 PM, Florian Bruhin <me at the-compiler.org> wrote:

> * Jonathan Mizrahi <mizrahi.jonathan at gmail.com> [2015-09-24 09:10:29
> -0400]:
> > When, exactly, is it necessary to use the @pyqtSlot decorator? Also, if a
> > signal calls a slot which has previously been garbage-collected, will
> that
> > cause problems in the program? My own simple tests seemed to show that
> > deleting slots, even pure Python slots which are not decorated, did not
> > cause a problem. But, are there cases where it does?
>
> I can't exactly pinpoint it, but I had various funny corner cases
> (especially with PyQt versions < 5.4 or so) with segfaults,
> RuntimeErrors, etc. which went away when I decorated the slots - so I
> now always decorate them.
>
> Florian
>
> --
> http://www.the-compiler.org | me at the-compiler.org (Mail/XMPP)
>    GPG: 916E B0C8 FD55 A072 | http://the-compiler.org/pubkey.asc
>          I love long mails! | http://email.is-not-s.ms/
>
> _______________________________________________
> PyQt mailing list    PyQt at riverbankcomputing.com
> https://www.riverbankcomputing.com/mailman/listinfo/pyqt
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20150924/f98ca640/attachment.html>


More information about the PyQt mailing list