If Things Go Wrong
Pages 39
- Home
- About
- Build Bootloader Win64
- Community
- Development
- Development Commit Messages
- Development Release
- Development Workflow
- FAQ
- Feature Ctypes Dependencies
- Features
- how to apply pull requests
- How to Contribute
- How to Report Bugs
- If Things Go Wrong
- License
- Program Tracing
- Projects Using PyInstaller
- Python 3 Port
- Recipe Collect Data Files
- Recipe Executable From Django
- Recipe Grab Window Focus
- Recipe Gtk Application
- Recipe Multiprocessing
- Recipe OpenSSL Certificate
- Recipe OSX Code Signing
- Recipe PyQt4 API Version
- Recipe python daemon package
- Recipe pytz zip file
- Recipe remove tkinter tcl
- Recipe Setuptools Entry Point
- Recipe subprocess
- Recipe Win Code Signing
- Recipe Win Load External DLL
- Recipes
- Running the test suite
- Search Helpers
- Supported Packages
- Trac Ticket Migration
- Show 24 more pages…
Clone this wiki locally
There are different areas of typical problems which can occur when using PyInstaller. For fixing problems in your application, it is critical to understand this:
-
Some required modules, shared libs or data files are not frozen (packaged, bundled) into the resulting exec.
This kind of problems are to be solved within the "freeze" phase by:- using
hiddenimportin the.spec-file. - collecting files or modules within the
.spec-file - implementing a new hook (or fixing an existing one)
- fixing a bug in PyInstaller.
To check if all your files are frozen, use
utils/archive_viewer.py. See Make sure everything is packaged for more information. - using
-
You application can not import some module, list modules, find data files, etc.
This kind of problems has to be solved within our application by:- adapting your application to be frozen (see the manual)
- If generic parts of your application are effected (e.g. commonly used packages like Tkinter, GTK, QT), adding a runtime-hook will help others users
Prior to solving "Type 2" problems, you need to ensure there are no "Type 1" problems. You first of all you need to find out which type of problem you are facing. See Before submitting a report for how to do this.
Please note: If your application is complex, there may be several "Type 1" and several "Type 2" problems.
-
PyInstaller crashes when packaging my program.
Please try the development version (zip, tar.gz) first. If even this version does not work, it looks like a bug. Please have a look at How to Report Bugs, which will help us a lot on solving the problem. -
I get an
ImportErrorwhen running the packaged version. What should I do? Please make sure, all modules required by you application are packaged. See Make sure everything is packaged for more information. -
I receive
Failed to execute script. What should I do? Build the app without--windowedand run it from a command prompt to get the full error output before submitting a bug report. -
My program crashes when running the packaged version. What should I do?
Please make sure, all data files required by you application are packaged. See Make sure everything is packaged for more information. -
I made it work by implementing a hook. Do you want it?
Yes, we'll happily integrate any hook which may be of interest for others. Please open a ticket and attach the hook. Or even better: submit a pull-request.