Python Forum
Thread Rating:
  • 1 Vote(s) - 2 Average
  • 1
  • 2
  • 3
  • 4
  • 5
can't run .exe file
#1
Hey! I have compiled my python file with pyinstaller and produced a .exe file, however my program doesn't want to run. I ran it through the shell and it printed out the following error message:
Error:
Traceback (most recent call last):   File "site-packages\PyInstaller\loader\rthooks\pyi_rth_qt5plugins.py", line 46, in <module>   File "c:\users\daugi\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 714, in load_module     module = loader.load_module(fullname) ImportError: DLL load failed: The specified module could not be found. Failed to execute script pyi_rth_qt5plugins
Does anyone know what could I possibly do to fix it? Many thanks!
Reply
#2
I have had very good luck with py2exe. Suggest that you give that a try,
basic instructions are here: https://pypi.python.org/pypi/py2exe/0.9.2.2

I have had difficulty with some packages using other methods. There are
always solutions, but sometimes not so evident.
py2exe seems to work most (if not all) the time.

One other thing that really seems to help is to create your application in a virtual environment.

If you need more detailed information on py2exe, see:
Reply
#3
The problem Larz60+ is that py2exe is not updated for Python 3.5 that he use.
Pyinstaller, Cx_freeze, pynsist 1.9 work for 3.5.

There is a bug rapport this.

You can look at these post1 post2.
Here i show usage of Pyinstaller and Cx_freeze and i like to use virtual environment when using these program.
Then there is less stuff that can go wrong.
Reply
#4
Quote:The problem Larz60+ is that py2exe is not updated for Python 3.5 that he use.

I have used the python 3 version: https://pypi.python.org/pypi/py2exe/0.9.2.2
with good results.
Reply
#5
(Feb-18-2017, 10:07 PM)Larz60+ Wrote: I have used the python 3 version: https://pypi.python.org/pypi/py2exe/0.9.2.2
It work up to 3.4,not for 3.5.
Reply
#6
I have a question but don't want to open a new topic. Can I create .exe file on Linux box?
"As they say in Mexico 'dosvidaniya'. That makes two vidaniyas."
https://freedns.afraid.org
Reply
#7
(Feb-19-2017, 07:19 AM)wavic Wrote: I have a question but don't want to open a new topic. Can I create .exe file on Linux box?
No to make a "exe" you need Windows.
Pyinstaller work in Linux it create a executable that work for linux.
Quote:PyInstaller is tested against Windows, Mac OS X, and Linux. However, it is not a cross-compiler:
to make a Windows app you run PyInstaller in Windows; to make a Linux app you run it in Linux, etc.
Reply
#8
I will go back to pyinstaller. Does it work with 3.6 also?
Reply
#9
(Feb-19-2017, 12:14 PM)Larz60+ Wrote: Does it work with 3.6 also?
Not yet Add support for Python 3.6 #2331
Cx_freeze work for 3.6,i did a test here.
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020