Does anyone know why pyinstaller
immediately fails after installed via pip
via anaconda 32bit
?
I installed pyinstaller via
"C:\Program Files\Python35-32\python.exe" "C:\Program Files\Python35-32\Scripts\pyinstaller-script.py" --onefile --windowed ex_btn.py
--onefile : create only exe, --windowed : exclude the prompting CMD, ex_btn.py : python script file.
This worked like charm.
This error seems to occur when Python’s (or PyInstaller’s) path contains a space (for example, when one installs Python to the Program Files (x86)
directory.)
I suspect that somewhere in PyInstaller’s source code there are some missing quotation marks.
Try installing Python in a path without spaces, and installing PyInstaller (via pip) to that path.
In my case, I uninstall and install pyinstaller, then every things work well.
It may relate to any changes within python after installation, so re-installing is a good choice.
uninstall:
pip uninstall pyinstaller
install:
pip install pyinstaller
As StationaryTraveller mentioned, you can work around this bug by calling script pyinstaller-script.py
Below is an example
C:>"C:\Program Files (x86)\Python35-32\python.exe" "C:\Program Files (x86)\Python35-32\Scripts\pyinstaller-script.py" script_to_compile.py
I had the same issue, even with pip and setuptools updated, and the problem was that pyinstaller-script.py, found in C:\Python35\Scripts\ directory, had the wrong path for python.exe.
Python on my system was somehow installed in AppData, but its' scripts and modules were being installed in C:\Python35\ folder.
Changing the first line of pyinstaller-script.py to the correct path of python.exe (Programs directory inside AppData), with quotes if there's any space in the folders' names inbetween, and it should work and no longer show the "Failed to create process". Example:
#!C:\Program" "Files" "(x86)\Python\python.exe
Using Windows10 and Python35 official installer got Python installed there somehow.
As of July 2016 the issue was reported as fixed, ugrading pip, setuptools and then uninstalling and installing pyinstaller should remedy the problem