Comments (5)
I'm running into problems with getting PyInstaller to build something on OSX. The build process apparently completes successfully, but when I come to run the application, I get exception ImportError: No module named 'PyQt5.Qsci'
.
@carlosperate or anybody else, do you have any ideas for how I can go about debugging this?
from mu.
I assumed instaling Qsci was a different step than what is currently on the install_osx.sh file, mostly because of the import error you mention, and because I had to sudo apt-get install python3-pyqt5.qsci
in ubuntu to get it to run.
Is your build environment able to launch the python program without throwing he same import error? If so, there is a small chance that PyInstaller is not figuring out the import requirements properly, and it can be added to the spec file as a "hidden import", however there is a clear dependency in the editor.py file, so I'd be surprised if that would solve it.
There is also a chance that it might be a fixed bug in PyInstaller. You check that by downloading the source code directly from github and run that pyinstaller.py file instead of the pyinstaller
command.
from mu.
Thanks @carlosperate for your input. I am able to launch the Python program without any problems -- I probably should've made that clearer yesterday!
build/pyinstaller/warnpyinstaller.txt
contains a bunch of warnings about missing modules, which includes:
missing module named 'PyQt5.Qsci'.QsciLexerPython - imported by 'PyQt5.Qsci', mu.editor
missing module named 'PyQt5.Qsci'.QsciScintilla - imported by 'PyQt5.Qsci', mu.editor
missing module named 'PyQt5.Qsci' - imported by mu.editor
Further digging shows that PyInstaller is trying to load the QSci
module from the wrong directory -- it's looking in /usr/local/Cellar/pyqt5/5.5.1/lib/python3.5/site-packages/PyQt5
, but it should be looking in /usr/local/lib/python3.5/site-packages/PyQt5
.
The first path is where homebrew puts the packages before symlinking them to the second path. I'll need to spend some more time getting cosy with pdb
to work out why it's looking in the second path.
from mu.
Ooh ooh ooh, I've commented out two lines in PyInstaller, and I've got something to work! See pyinstaller/pyinstaller#1750 for details.
from mu.
That's great progress @inglesp! Let's see how the bug report goes, if it gets fixed on their git repository we can always pull that on the travis ci installation script. If not, we could have a bit of a hacky-temporary-solution to clone and apply a patch before using PyInstaller.
from mu.
Related Issues (20)
- Test Failed in Windows build
- ERROR: No matching distribution found for pup HOT 2
- mu editor
- mu editor
- தமிழ் Translation of Mu Tool and Website
- ImportError: Symbol not found: ____chkstk_darwin; Also unable to write venv.json HOT 2
- `pkg_resources` is deprecated and removed in Python 3.12
- The Mu mac version built in the local is not opened in other MacOSs. HOT 2
- The WIN32 version is made by a local build of my personal WIN 10 platform is not opened. HOT 4
- MacOS keyboard layout US-Intl erases all quotes (single, double) in ESP REPL
- Trying to Turkish Translation
- sfu
- If the executed a part of App is out of a Desktop of Windows OS, the part will be painted to black color. And the black part will be leave permanently without recovery.
- Line numbers are unreadably small when you zoom out
- Python tkinter applications fail with "append_pending_request: Assertion `!xcb_xlib_unknown_seq_number' failed." HOT 2
- Running tests with Python 3.8 fails HOT 1
- Crash when opening for the first time HOT 1
- Enhancement: Using `uv` to manage venv and pip install
- mu-editor/mu
- MU incredibly slow with print HOT 2
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 mu.