PyFinalize crash when mixing sip and PyQt-Builder extensions?

Patrick Stinson patrickkidd at gmail.com
Tue Oct 25 17:39:24 BST 2022


I am getting a crash on exit when I include both my basic sip extension and
PyQt-Builder extension. If I A) only import my pure sip extension in python
and not the PyQt-Builder extension, or B) change the sip extension builder
to PyQt-Builder, it doesn't crash. Import order doesn't matter.
PyQt-5.15.7, python-3.10

The macOS Crash Report says:

Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib            0x7ff80be2b00e __pthread_kill + 10
1   libsystem_pthread.dylib          0x7ff80be611ff pthread_kill + 263
2   libsystem_c.dylib                0x7ff80bdacd24 abort + 123
3   libsystem_malloc.dylib            0x7ff80bc8a357 malloc_vreport + 551
4   libsystem_malloc.dylib            0x7ff80bc8d52b malloc_report + 151
5   Family Diagram                       0x1071ee985 _PyObject_Free + 165
6   Family Diagram                       0x107359e71 finalise + 177
7   Family Diagram                       0x1072e8bd9 Py_FinalizeEx + 409
8   Family Diagram                       0x106b2d776 pyqtdeploy_start(int,
char**, _inittab*, char const*, char const*, char const**) + 1862
(pyqtdeploy_start.cpp:236)
9   dyld                                 0x1147cc52e start + 462

It's complaining about a pointer being freed that wasn't allocated.

I'm not sure where to start with that stack trace. I'd just change the
project builder on the pre sip extension but it's shared with a server
process and I need to avoid a Qt/qmake dependency.

Cheers,
-Patrick
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20221025/42b3cbbf/attachment.htm>


More information about the PyQt mailing list