Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fail: from .py to .exe
#1
hi, friends.

I have such a problem, when want to convert my python code into executable, it is being converted successfully, but does not work. when running the exe file it gives
"Error loading Python DLL 'C\user\python36.dll'. LoadLibrary: the Specified modul could not be found"

So, I use ">pyinstaller python_file.py --windowed -- clean" this method.

what is wrong, thanks in advance

>pyinstaller -F python_file.py

this gave the following error
Reply
#2
Try:
pyinstaller --onefile --windowed --clean
If not --onefile you can not move .exe without also having python36.dll in same folder.
With option --onedir all files in that folder most move together,also .exe .dll ect...
Reply
#3
Please look at the screenshot.

when, moveing the python36.dll file , it gives another error "Failed to execute script : pyi_rth_multiprocessing"

Attached Files

Thumbnail(s)
   
Reply
#4
Look at this post,where i fix this error.
You try to build Pandas it has a lot of dependencies.
I also always build it in virtual environment when trouble shooting errors,
to have more control over dependencies.

So the fix was this added to spec file.
hiddenimports=['pandas._libs.tslibs.timedeltas'],
Then run spec file.
pyinstaller --clean your.spec
Reply
#5
it worked, thanks alot :)
Reply


Forum Jump:

User Panel Messages

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