When you try to compile your scripts into an executable file, pyinstaller gives the following error message: failed to create process.
Typically, this happens when it is installed in a directory that has space. Example: C:\Program Files\…
To solve this issue, go to the directory where the pyinstaller is installed (C:\Program Files (x 86) \Python35-32\Scripts\) and edit the pyinstaller-script.py file.
The first lines will be similar to these:
#!c:\program files\python 3.5\python.exe # EASY-INSTALL-ENTRY-SCRIPT: 'PyInstaller==3.1.1','console_scripts','pyinstaller'
Add quotes to the first line, like this:
#!"c:\program files\python 3.5\python.exe"
Save the file and try again.
*Update: September 5th, 2018*
I have installer Python on a brand new Windows 10 machine and I got this error. When i checked pyinstaller-script.py, the path was already between double quotes.
To solve this, what I did was simple: Reinstalled pyinstaller. Yep, that worked with no side-effects whatsoever.
If you want to try this, here’s the commands:
pip uninstall pyinstaller pip install pyinstaller
Latest posts by Breno RdV (see all)
- What is a metaclass and how it works. (#python #dev #metaclass) - January 11, 2023
- Understanding the magic of Generators. (#python, #dev, #generator, #iterator) - December 28, 2022
- Facebook comments on posts. (info) - June 23, 2020