[PyQt] Embedding w/ multi-threaded Python

McKay Davis mckay.cpp at gmail.com
Tue Mar 10 00:12:37 GMT 2009


All,

We are encountering difficulties embedding PyQT into our application.  In
our situation, we provide the capability to run multiple python interpreters
simultaneously along with the main thread PyQT interpreter.

We try to correctly manage the python global interpreter lock in such a way
so that we can run PyQT python code in conjunction with non-PyQt python code
running in other threads.  What we have found however, is that under some
circumstances (ie , our application will deadlock since there appears to be
an implicit assumption that the global interpreter lock is already held the
moment that slot code is invoked by PyQT.

We can assure this to be the case, but only at the expense of locking other
python code threads out of the global interpreter lock.  Are there any
provisions to accommodate what we are trying to do that we are not making
use of?  Or is this perhaps a known issue?  Are there any workarounds?  We
would appreciate any help or tips on this.

Thanks,

McKay Davis
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20090310/da935ef4/attachment.html


More information about the PyQt mailing list