A
A
Alexey R2019-07-02 20:33:38
Python
Alexey R, 2019-07-02 20:33:38

exe created by pyinstaller on Windows won't run. Why?

Good afternoon dear community. I recently started learning python . So far I really like it, but progress is too slow due to the main work. I decided that it was necessary to combine the study with the real workflow. Wrote small scripts for automation, and decided to make the first application with a GUI. PyQT5 was taken as a basis . The application is very simple and clumsy in terms of code, but it is the first. It starts and runs (as .py and as .exe) . The problem is that after assembling this program into a single .exe file, it does not run on other computers . That is, everything works on my machine. In a VMware Windows 7 SP1, 10 virtual machinethe file also starts up and works. But at work on a real machine, after running the .exe file, nothing happens. In the task manager, the program is active, but there is no GUI. Apparently this is a GUI error (for some reason it seems to me so). Tell me if there are any ways to debug in such cases, how to understand what the problem is.
Link to py files and exe itself
https://drive.google.com/file/d/12905ZaPCXDgGyVwhr...
https://drive.google.com/file/d/19rgf7lN3m6Le5iIsj...

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
PrAw, 2019-07-04
@Axeles

Alexey R , I looked at the application, some kind of excessive
QT overkill is thick in itself, everything is stuffed into a binary, it is unpacked into TEMP at startup and only after that it starts. On a slow hard drive and under antivirus everything will be even longer. After completion, everything carefully unpacked is deleted.
Therefore, recommendations
1. Look towards the interface on TKinter, it is smaller, it is a little more difficult to write, but it will be better to start, plus it comes out of the box
https://python-textbok.readthedocs.io/en/1.0/Intro...
2. In the case of PyInstaller, look towards "Bundling to One Folder", there you won't have to repack anything at each launch, performance will increase.
Yes, the application will be presented as a binary and a set of files, but what's the difference? If you want a beautiful installer - use NSIS, the simplest of the free ones that I used
https://nsis.sourceforge.io/Main_Page
And the recommendation in the comments from Sergey Gornostaev actually solved the problem originally asked in the post

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question