ImportError: No module named 'PyQt5.sip'
Gabriele Bulfon
gbulfon at sonicle.com
Mon Apr 27 22:19:05 BST 2020
Great Phil, that's where I pulled sources for both of them.
I have built and packaged PyQt5-sip and PyQt5 from those sources, after building and packaging sip5 and PyQt-builder.
Maybe there's something wrong in what I'm delivering to the system with PyQt5-sip?
Here's a brief of the files delivered by my package, as in the package definition file (pkg, solaris).
I derived this from the prototype area generated by the build/install on the prototype install root.
I bet something is wrong with the sip.cpython-35m.so file...I still don't understand how these cpython so files are looked up, but that is what the build system created in the prototype area.
dir path=usr
dir path=usr/lib
dir path=usr/lib/python$(PYVER)
dir path=usr/lib/python$(PYVER)/vendor-packages
dir path=usr/lib/python$(PYVER)/vendor-packages/PyQt5
dir path=usr/lib/python$(PYVER)/vendor-packages/PyQt5_sip-12.7.2-py$(PYVER).egg-info
file usr/lib/python$(PYVER)/vendor-packages/PyQt5/sip.cpython-35m.so path=usr/lib/python$(PYVER)/vendor-packages/PyQt5/sip.cpython-35m.so
file path=usr/lib/python$(PYVER)/vendor-packages/PyQt5_sip-12.7.2-py$(PYVER).egg-info/PKG-INFO
file path=usr/lib/python$(PYVER)/vendor-packages/PyQt5_sip-12.7.2-py$(PYVER).egg-info/SOURCES.txt
file path=usr/lib/python$(PYVER)/vendor-packages/PyQt5_sip-12.7.2-py$(PYVER).egg-info/dependency_links.txt
file path=usr/lib/python$(PYVER)/vendor-packages/PyQt5_sip-12.7.2-py$(PYVER).egg-info/top_level.txt
Thanks for your help!
Gabriele
Sonicle S.r.l.
:
http://www.sonicle.com
Music:
http://www.gabrielebulfon.com
Quantum Mechanics :
http://www.cdbaby.com/cd/gabrielebulfon
----------------------------------------------------------------------------------
Da: Phil Thompson
A: Gabriele Bulfon
Cc: pyqt at riverbankcomputing.com
Data: 27 aprile 2020 18.40.16 CEST
Oggetto: Re: ImportError: No module named 'PyQt5.sip'
You are talking about SIP v5, Patrick is talking about SIP v4.
If you must build from sources then you can get the source package for
the PyQt5.sip module from PyPI...
https://pypi.org/project/PyQt5-sip/#files
The PyQt5 sources are also on PyPI...
https://pypi.org/project/PyQt5/#files
To do the build you must also have SIP and PyQt-builder installed from
PyPI.
Phil
On 27/04/2020 17:19, Gabriele Bulfon wrote:
Ok, sip sources have no configure.py:
ChangeLog
code_generator
doc
examples
LICENSE
LICENSE-GPL2
LICENSE-GPL3
MANIFEST.in
NEWS
PKG-INFO
pyproject.toml
README
setup.cfg
setup.py
sip.egg-info
sipbuild
I only have setup.py
I got the sources from here:
https://files.pythonhosted.org/packages/bc/dd/aa60ae73bc213466fd158e3d8b91d55ac00a248b14a98919bfe0e12c5d74/sip-5.2.0.tar.gz
Is this correct?
Sonicle S.r.l.
:
http://www.sonicle.com
Music:
http://www.gabrielebulfon.com
Quantum Mechanics :
http://www.cdbaby.com/cd/gabrielebulfon
Da:
Patrick Stinson
A:
Gabriele Bulfon
Cc:
pyqt at riverbankcomputing.com
Data:
27 aprile 2020 18.10.21 CEST
Oggetto:
Re: ImportError: No module named 'PyQt5.sip'
I mean when the option you passed to sip’s configure.py when building
sip.
On Apr 27, 2020, at 7:34 AM, Gabriele Bulfon
wrote:
Hello,
do you mean something like this?
/usr/bin/sip-build --no-make --sip-module PyQt5.sip --qmake
/usr/lib/qt/5.14/bin/amd64/qmake --confirm-license
Thanks!
Gabriele
Sonicle S.r.l.
:
http://www.sonicle.com
Music:
http://www.gabrielebulfon.com
Quantum Mechanics :
http://www.cdbaby.com/cd/gabrielebulfon
Da:
Patrick Stinson
A:
Gabriele Bulfon
Cc:
pyqt at riverbankcomputing.com
Data:
27 aprile 2020 17.19.48 CEST
Oggetto:
Re: ImportError: No module named 'PyQt5.sip'
Did you build sip with “—sip-module PyQt5.sip”?
On Apr 26, 2020, at 11:45 PM, Gabriele Bulfon
wrote:
Hello,
I've built and packaged from sources PyQt5 for our XStreamOS/illumos
distro.
Your package is a requirement for LightDM web-greeter.
After building and installing all the packages, trying to run
web-greeter I receive this errors:
XStreamOS Chandra (powered by illumos) SunOS 5.11 March 2020
gbulfon at xstreamos:~$ web-greeter
Traceback (most recent call last):
File
"/usr/lib/python3.5/vendor-packages/whither/toolkits/bootstrap.py",
line 31, in
from .qt.window import QtWindow as Window
File
"/usr/lib/python3.5/vendor-packages/whither/toolkits/qt/window.py",
line 34, in
from PyQt5.QtWidgets import (
ImportError: No module named 'PyQt5.sip'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3.5/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.5/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/usr/bin/web-greeter/__main__.py", line 37, in
File "/usr/lib/python3.5/vendor-packages/whither/app.py", line 33, in
from .toolkits.bootstrap import Application, Window, WebContainer
File
"/usr/lib/python3.5/vendor-packages/whither/toolkits/bootstrap.py",
line 38, in
from .gtk.window import GtkWindow as Window
File
"/usr/lib/python3.5/vendor-packages/whither/toolkits/gtk/window.py",
line 34, in
gi.require_versions({'Gtk': '3.0', 'Gdk': '3.0'})
AttributeError: module 'gi' has no attribute 'require_versions'
I also have built and installed pyqt5-sip 12.7.2.
Any idea what's missing?
Or, where should I look for missing stuff? What is it looking for?
Thanks,
Gabriele
Sonicle S.r.l.
:
http://www.sonicle.com
Music:
http://www.gabrielebulfon.com
Quantum Mechanics :
http://www.cdbaby.com/cd/gabrielebulfon
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20200427/7cdad388/attachment-0001.htm>
More information about the PyQt
mailing list