Pyinstaller Onefile Not Including Data Files
I have an application I would like to package into a single file, but am running into issues with the --onefile option including html, js, and css files. The process works fine whe
Solution 1:
So I ended up solving this one for myself. After reading through the docs again I noticed that here is a small blurb that says in one file mode the exe will create a temp folder named MEIPASS
this is the folder referenced in the answer I linked. However, in my case as I have multiple data files that are swapped out in my app I had to change all of the references to those files to call sys._MEIPASS+ '/' + file
instead of the QDir.currentPath() + '/' + file
I had been using (This app was built using PyQt4).
Furthermore, for the CSS and js files associated with my html I had to make sure that the href calls where in the same folder.
Post a Comment for "Pyinstaller Onefile Not Including Data Files"