|
d |
|
Packaging is tricky. The goal is to make an executable .exe for Windows (Mac OSX and Linux support later).
|
|
\ No newline at end of file |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## fman build system (fbs)
|
|
|
|
|
|
|
|
For stand-alone executable from PyQt5
|
|
|
|
|
|
|
|
- https://build-system.fman.io/manual/
|
|
|
|
- https://github.com/mherrmann
|
|
|
|
- https://github.com/mherrmann/fbs-tutorial
|
|
|
|
- https://build-system.fman.io/troubleshooting
|
|
|
|
- https://www.learnpyqt.com/courses/packaging-and-distribution/packaging-pyqt5-apps-fbs/
|
|
|
|
|
|
|
|
```
|
|
|
|
pip install fbs PyQt5==5.9.2 pyinstaller==3.4
|
|
|
|
```
|
|
|
|
|
|
|
|
**Not sure this installation works anymore. Since v0.20.0 fbs Pro is used.**
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## Notes about specific modules
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### plotly
|
|
|
|
|
|
|
|
After packaging, the **QtWebEngineView** does not work. If the exe is executed, this error message appears:
|
|
|
|
|
|
|
|
``Could not find QtWebEngineProcess.exe``
|
|
|
|
|
|
|
|
**QtWebEngineView.exe** cannot be found, but it is available in the folder:
|
|
|
|
|
|
|
|
``target\DIIVE\PyQt5\Qt\bin\QtWebEngineProcess.exe``
|
|
|
|
|
|
|
|
There is a solution to this that worked:
|
|
|
|
|
|
|
|
https://stackoverflow.com/questions/67060913/pyinstaller-could-not-find-qtwebengineprocess-exe-for-pyqt5-web-application
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### statsmodels
|
|
|
|
|
|
|
|
Generates an error when trying to use fbs. Code compiles OK, but then on trying to execute the script there is an error and app does not start.
|
|
|
|
|
|
|
|
In short:
|
|
|
|
|
|
|
|
- DOES NOT WORK: import statsmodels.api as sm
|
|
|
|
- **WORKS: import statsmodels.formula.api as smf**
|
|
|
|
|
|
|
|
More Info
|
|
|
|
|
|
|
|
- https://github.com/pyinstaller/pyinstaller/issues/3921
|
|
|
|
- https://stackoverflow.com/questions/56810739/error-when-using-statsmodels-with-pyinstaller
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### pandas-profiling (not used)
|
|
|
|
|
|
|
|
Convenient module that generates statistical output that can be exported to a file. Unfortunately including this module in the code generates this error when trying to run the .exe on Windows:
|
|
|
|
|
|
|
|
> confuse.ConfigReadError: file L:\Dropbox\luhk_work\Programming\ProjectRoom Repository\Amp_INDEV\Amp_dist_test\target\Amp\pandas_profiling\config_default.yaml could not be read: [Errno 2] No such file or directory: 'L:\\Dropbox\\luhk_work\\Programming\\ProjectRoom Repository\\Amp_INDEV\\Amp_dist_test\\target\\Amp\\pandas_profiling\\config_default.yaml'
|
|
|
|
|
|
|
|
GitHub Link
|
|
|
|
|
|
|
|
- https://github.com/pandas-profiling/pandas-profiling
|
|
|
|
|
|
|
|
Installation:
|
|
|
|
|
|
|
|
```
|
|
|
|
pip install pandas-profiling
|
|
|
|
``` |
|
|
|
\ No newline at end of file |