[QGIS-Developer] import PyQt5.QtCore failed (from OSGeo4W python)

Idan Miara idan at miara.com
Sun May 19 02:23:21 PDT 2019


Hi all,

Thanks for helping me to figure this out.
I found the missing package - sip-qt5.
More specifically sip.pyd from that package - if this file is missing then
"import PyQt5.QtCore" will fail.
Thus, I think the package pyqt5 should be dependent on sip-qt5.

Idan.

On Mon, 4 Mar 2019 at 16:45, Idan Miara <idan at miara.com> wrote:

> Hi,
>
> I've used the OSGeo4W setup to install PyQt5 and then ran:
> import PyQt5.QtCore
> from a python shell (OSGeo4W.bat with qt5_env, py3_env inside)
> I'm getting the following error:
>
> D:\OSGeo4W64>python
> Python 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit
> (AMD64)] on win32
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import PyQt5.QtCore
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
> SystemError: initialization of QtCore failed without raising an exception
> >>>
>
> Running the same command in a QGIS python shell works fine (same batch
> file)
> Please advise.
>
> Kind regards,
> Idan
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20190519/2b93f3b6/attachment.html>


More information about the QGIS-Developer mailing list