For a while now, I've been trying to compile a Julia package into an EXE with little success. Recently, I decided to take a look into wrapping it with Python and then transforming it to an EXE. This has worked great except the EXE crashes on startup show the attached error message. Can any of ya'll help me understand what the error is or even if this is the correct path? The error persists with the --onedir attribute as well.
In your command prompt,
pip uninstall typing
Then run your pyinstaller command again. It won't crash
Related
I programmed a small application and compiled it using pyinstaller. However I can't run my compiled .exe. It shows this error:
Does anyone know how to fix it and create a working .exe?
pyinstaller --noconfirm --onedir --windowed --icon " "
I had the exact same problem. For me it turned out to be a bug related to pyinstaller 4.7 and python 3.9.8. I uninstalled python 3.9.8 and installed 3.9.5 instead and it worked perfectly with pyinstaller -w, my exe file runs without a console window now, and without any errors.
This happens because of --windowed argument in Windows. Without it it compiles and works ok, but you need to keep the Command Prompt window open too. Still trying to find a work-around.
I have written some code in python. It is working fine from command prompt. So, I have tried to create .exe application using pyinstaller. The command i used is:
pyinstaller --onedir --windowed Result_generator.py
The app is build successfully. But, when I open it, it is showing an error saying "Fatal Error" and was unable to execute it. It immediately shuts down when i open it. But the same code works fine using command prompt execution. Please help me with this. Thanks in advance!
Doubt:
I am using xlsxwriter package. Does it effect the application? Does pyinstaller work with python 3.6.4?
I am trying to create an .exe file such that when run on any windows 10 pc will run without requiring any installations. What I tried using was:
pyinstaller --onefile main.py
I ran the exe file on a friend's computer and it turns out that it required first python2.7 to be installed, then it said that modules weren't installed i.e; no module named datetime found. The executable finally ran after I installed all dependencies on my friend's computer but the whole point of creating .exe file was useless, I might as well have just typed python main.py after doing so much. Is there an appropriate way I could get an .exe file from .py which wont require anything to be installed? Like an actual standalone app. Thank you!
Actually this should work. I never had problems with pyinstaller, yet. Maybe reinstall pyinstaller or make sure to use the newest version. Also try first of all an easy "helloWorld"
input("hello from Console.\nPress Enter to close it :)")
Just tried this one on a colleague's machine that has no python installed. And it worked well.
I've had good results using the pyinstaller module to one file even when running code with multiple dependencies on machines without python installed. Reading the documentation helped There is a comprehensive list of python to exe compilers in another stackoverflow question: a good python to exe compiler?
Recently, I used sklearn to do linear regression analysis, and the code was compiled and run by me. But when I packaged to the .exe file with pyinstaller, An error has occurred:"ImportError:no module name typedefs" after running. When I added "--hidden-import sklearn.neighbors.typedefs" after the command, my program stopped running directly. This question is bothering me now. Can you help me?
I had exactly the same problem, and adding
--hidden-import sklearn.neighbors.typedefs
to my pyinstaller command-line call fixed my problem. Therefore I suspect that an additional problem occurred in your case
No no no, you have to run pyinstaller again like this:
pyinstaller --onefile your_program.py --hidden-import sklearn.neighbors.typedefs
I think you added that line to the already compiled program, hence your error.
I need to make a script.py to be an executable file.
I researched around for a little bit and found that in order to do that on a 3.5 python script I had to install pyinstaller and type a line like this into the command prompt:
pyinstaller --onefile guiFileOpener_1_1.pyw
But when I did this, I got this error message:
failed to create process
I am not sure what I am doing wrong here...