-
Notifications
You must be signed in to change notification settings - Fork 125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pyinstaller for PyQt5 and Pyvis requires some manual copying of files. #141
Comments
This is normal behavior. Data files (such as Since PyInstaller 4.3, you can also use
That's probably because PyInstaller 4.3 does not yet support
Nope, you're running into usual PyInstaller issues: the data collection not being fully automatic + the fact that the fixes for
Explained above.
The library itself (its python modules) are probably getting collected just fine, and it is just the data files data are missing.
This is a red herring; if there are |
I guess then that that leaves this issue as a hook request for pyvis so this can scoot over to the hooks repo. |
Thanks @rokm and @bwoodsend. I will try with PyQt5 5.15.2 and use |
@rokm, I have tried your suggestions. Downgrading PyQt5 to 5.15.2 and use of --collect-data pyvis helped in resolving the error messages I have mentioned. Issue 1Discription: Content of qt.conf file:
Question:
Issue 2Discription Note: In the same machine if I change the directory and run the program, it works fine. If I change to another machine it creates the problem. I have not created as a single file exe yet, so I can check that the nx.html file is created in the other system too. Question:
|
This should work out of the box. The Can you check if
This is probably path issue. Your original code snippet is creating the
Where is it created? Can add an
What exactly does this mean? Is the view window completely blank, is it showing a file-not-found error, or something else? |
@rokm, as you suggested earlier, I have downgraded PyQt5 to 5.15.2. The installation process showed PyQt5 is successfully installed and the QtWebEngineProcess.exe file is getting copied whenever I ran pyinstaller. After some attempts when I checked PyQt5 version using pip show pyqt5 and pip show pyqtwebengine, I understood some cache was not cleared properly due to which version conflicts were there. So I removed all Qt related libraries and reinstalled them. This reinstallation solved my issue 1, and this also solved the issue 2. When creating the binaries as a single file, the path issue comes, otherwise it was showing blank window. Now I suppose it is due to the cache issue with library installation. Both issues are resolved now. Thanks a ton for your kind support! |
Issue:
I have created a network graph using PyVis and used PyQt5's QWebEngineView to show the html output created using PyVis. I used anaconda and spyder to develop the code and graph is shown in as a windows application. When I try to use Pyinstaller to convert the python code to binaries, the library contents of PyVis is not properly getting converted into binaries (the error it shows is "<path_to_binaries>/dist/<app_name>/pyvis/template.html is not found". The template.html file is inside the PyVis, so if I manually copy that entire package from virtual environment to the dist folder created by Pyinstaller, then it works. The second problem is with PyQt5; the QtWebEngineProcess.exe has to be copied to "<path_to_binaries>/dist/<app_name>/PyQt5/qt/bin" location. Otherwise the application fails.
Note: Earlier I tried to do with conda packages, but "mkl_intel_thread_1.dll" file missing error came. Then I created new virtual environment and used pip to install all the packages, then that error was taken care (as pip does not install mkl library when installing numpy).
System configuration:
Code Snippet:
Questions:
The text was updated successfully, but these errors were encountered: