Comments (5)
Use zip_include_packages:
https://github.com/marcelotduarte/cx_Freeze/blob/main/samples/pyqt5/setup.py#L33
from cx_freeze.
I cloned the repo and built the pyqt5 example using python3 setup,py build.
I then ran the test_pqt5 it gives me the same partially initialized error.
The PyQT i am using is the default PyQT5 installed at the system level in ubuntu 22.
Python 3.10.12 (main, Nov 20 2023, 15:14:05) [GCC 11.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import PyQt5 as pt
>>> pt.__path__
['/usr/lib/python3/dist-packages/PyQt5']
Could this be what is causing the conflict or issue? I am running ubuntu 22 on a orange pi sbc board. The pyqt app opens normally if i do python3 test_pyqt5.py.
Edit 1
I tried the same sample on my amd laptop too, its giving the same error, so it should not be a device or OS issue.
from cx_freeze.
I use a virtualenv and install cx_Freeze and pyqt5 using pip (see also README).
I do not test with system pytq5. I test it using conda-forge too.
from cx_freeze.
I have to use the system PyQt5 package because, on my sbc, the PyQT5 package cannot be installed through pip. It needs to be built from source.
Is it feasible to make cx_freeze use the system pip package? if so can you tell me the steps, else i assume I will have to try with a source build which currently doesnt seem feasible.
from cx_freeze.
The program 'main_qthread_docker.py' runs in Python?
python3 main_qthread_docker.py
works?
I installed pyqt5-dev (sudo apt install pyqt5-dev)
And tried:
$ python3
Python 3.10.12 (main, Nov 20 2023, 15:14:05) [GCC 11.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import PyQt5 as pt
>>> pt.__path__
_NamespacePath(['/usr/lib/python3/dist-packages/PyQt5'])
>>>
$ python3 samples/pyqt5/test_pyqt5.py
Traceback (most recent call last):
File "/home/marcelo/github/cx_Freeze/samples/pyqt5/test_pyqt5.py", line 5, in <module>
from PyQt5.QtCore import Qt
ModuleNotFoundError: No module named 'PyQt5.QtCore'
So the sample did not work with system python. This works w/ pyqt5 from pypi.
Do I need more packages than pyqt5-dev?
from cx_freeze.
Related Issues (20)
- Pyside6 missing base translation file HOT 2
- cx_Freeze with torch.multiprocessing using wrong source in child processes HOT 31
- ERROR: THESE PACKAGES DO NOT MATCH THE HASHES FROM THE REQUIREMENTS FILE. HOT 4
- Error message: no base named 'console' ('console-cpython-311-win_amd64') for python 3.11 HOT 25
- Reducing the Size of PyTorch-Based Executable HOT 1
- PyGObject hook broke in 7.1.0 HOT 4
- cxfeeze example references non-existent CLI option
- PyQt6 import error in cx_Freeze 7.1, missing DLL HOT 1
- Version 7.1.0 (and 7.1.0.post0) break FastAPI/hypercorn HOT 7
- Multiprocessing Manager Class Causes Infinite Loop on Mac OS (intel) HOT 18
- Building with pyproject.toml does not include local package HOT 3
- Windows Service cannot find required configuration files after creating .exe using cx_Freeze HOT 11
- Extend DMG functionality by using an external library HOT 1
- Error while building Qt6 sample on MacOSX HOT 12
- MKL hook trigger an error during setup HOT 3
- possible regression? cx_freeze 6.16 - 7.1 for possibly scipy HOT 12
- Could not Find Module vcomp140.dll HOT 2
- numpy 2.0 support added
- test_cli.py::test_import_tomli FAILS: "ImportError: No module named setuptools.extern" HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cx_freeze.