Crash when emitting PythonQt.Signal

Hi, I have some qt widgets that have some extra callbacks as signals, but I have a crash every time that I call emit. I have this problem with the latest stable and also the nightly build from a few days ago.

The repro steps are quite simple:
import qt
qt.Signal().emit()

This issue seems to already have been reported but I can’t work around it by using another mechanism because I’d have to change a lot UI code that’s already written.

The mentioned threads are: Custom Signal/Slots with PythonQt and Use of qt.Signal leads to a crash on exit

1 Like

You must not emit signals on behalf of another Qt object.

Tell us a bit more about what you are trying to achieve and we can help with finding a good design for it.

Sorry, the example was a bit too contrived.

As I was trying things out I was calling emit from the console and got the mentioned crash.
Instantiating the widget and actually using the UI doesn’t show the crash.

1 Like