[PyQt] QApplication.libraryPaths() bug?

Marcus Ottosson konstruktion at gmail.com
Mon Feb 9 11:18:41 GMT 2015


I'm experiencing some odd behaviour when querying the results
of QApplication.libraryPaths().

>>> import sys
>>> from PyQt5 import QtWidgets
>>> app = QtWidgets.QApplication(sys.argv)

This works fine.


However, when querying libraryPaths() before instantiating QApplication, I
get an error.

>>> import sys
>>> from PyQt5 import QtWidgets
>>> QtWidgets.QApplication.libraryPaths()
[]
>>> app = QtWidgets.QApplication(sys.argv)
This application failed to start because it could not find or load the Qt
platform plugin "windows".


And the results of libraryPaths() differ when run afterwards.

>>> import sys
>>> from PyQt5 import QtWidgets
>>> app = QtWidgets.QApplication(sys.argv)
>>> QtWidgets.QApplication.libraryPaths()
[u'C:/Python27']


It's happening on PyQt 5.3.1 and 5.4. Is this a bug?

Best,
Marcus

-- 
*Marcus Ottosson*
konstruktion at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20150209/8ab48485/attachment.html>


More information about the PyQt mailing list