[PyQt] QRunnable / activeThreadCount() issue
phil at riverbankcomputing.com
Mon Jul 10 16:47:47 BST 2017
On 7 Jul 2017, at 12:22 pm, Hazen Babcock <hbabcock at mac.com> wrote:
> I'm not sure if this is the expected behavior or not, but the following will almost always freeze up at the call to threadpool.activeThreadCount() after a random number of iterations due I assume to some issue with Python / Qt memory management. If I use setAutoDelete(False) and keep references to the QRunnables then the problem goes away. I've observed this behavior on both a linux and a Windows 7 platform.
I think this is fixed in tonight's snapshot. The problem seems to be a deadlock between the GIL and an internal QThreadPool mutex.
More information about the PyQt