[PyQt] Conflict between setuptools & requirements in official PyQt5 docs

Phil Thompson phil at riverbankcomputing.com
Fri Feb 12 11:56:52 GMT 2016


On 11 Feb 2016, at 2:34 am, Kovid Goyal <kovid at kovidgoyal.net> wrote:
> 
> On Wed, Feb 10, 2016 at 03:42:53PM +0000, Phil Thompson wrote:
>>    if __name__ = '__main__':
>>        app = QApplication([])
>>        gui = QWidget()
>>        gui.show()
>>        app.exec()
>> 
>> ...there shouldn't be a problem with crashes on exit. If anybody has an example where they think this is not the case then I'd like to know.
> 
> The very first PyQt5 crashing on exit example I posted over a year ago, still crashes about 1
> in 20 times, but only on Linux, following that exact pattern.
> https://riverbankcomputing.com/pipermail/pyqt/2014-October/034941.html
> 
> Details of my system:
> Kernel 4.4.1 x64
> PyQT 5.5.1
> Qt 5.5.1
> sip 4.16.9
> 
> Unfortunately, the crash involves stack corruption, so back traces are
> fairly useless, and I cannot get it to happen when running under a
> debugger.
> 
> This crash also happens with about the same frequency in a real world
> application, which is how I first noticed it. Unfortunately, in that
> case there is no simple fix since there are complex reference
> relationships between top level widgets, the application object and so
> on.
> 
> For a real world example that crashes reliably, on every exit, see this
> QWebEngine based application:
> https://github.com/kovidgoyal/vise
> Changing this line https://github.com/kovidgoyal/vise/blob/master/vise/main.py#L223
> to True causes it to crash on exit on every invocation. All that line
> does is enable remote debugging in QWebEngine, no other python level
> changes are involved.
> 
> This is again on linux, I have not tried it on other platforms.
> 
> You can run the application by (needs PyQt, libsodium installed):
> 
> git clone https://github.com/kovidgoyal/vise.git
> python3 vise

As far as I can see this isn't an example of the PyQt crashes-on-exit problem. Granted it does crash on exit when you set the QTWEBENGINE_REMOTE_DEBUGGING environment variable, but that just looks like a Qt bug.

Phil


More information about the PyQt mailing list