[MacTUG] Fwd: Seeking advice on using Pyinstaller for Mac

Marlon A. Griffith m3griffi at uwaterloo.ca
Fri Dec 3 12:25:31 EST 2021


Hi guys,

Can anyone provide some suggestions?

tia,
Marlon


-------- Forwarded Message --------
On Fri, Dec 3, 2021 at 9:59 AM Eric Croiset 
<ecroiset at uwaterloo.ca<mailto:ecroiset at uwaterloo.ca>> wrote:

Hi Erick,

We are currently working on an ecampus Ontario project that involves the 
development of python-based simulations. The students will be able to 
download the executable file. We are ok with windows-based systems, but 
we are facing issues with macOS systems (and we know that lots of 
students are using Apple products). I would like to know if you know 
someone in Engineering Computing that could help us creating macOS 
bundles using Pyinstaller.

More specifics about the problems are as follows:
We are currently using Pyinstaller to create macOS bundles of a Tkinter 
GUI in Python. The command I used was: ‘pyinstaller --onefile --windowed 
--name=Shortcut_Distillation_Simulation --icon=./Assets/uwicon.ico 
Distillation_v10_MIP_EW.py’. It generates two files: Application and 
Unix Executable File. When running the Application by double-clicking on 
the icon in Finder, it opens and closes immediately. The Unix Executable 
File runs fine.

Context:
Pyinstaller version: 4.7; Python version: 3.7.3; Platform: macOS 
Monterey 12.0.1

Tried:
We tried to comment out a part of code each time to find the source of 
the problem. We figured out that when commenting out lines shown below, 
the Application and Unix Executable File generated using Pyinstaller 
will both run perfectly. I have attached the package with source code 
and supporting files to this email.
[cid:17d8137263a5b16b21]

I cc John Zhang and Hao Wang who have been involved in this project. Hao 
is the student who is writing the code and should be cc’d/contacted to 
get more info if needed.

We are kind of stuck on this and it would be much appreciated to direct 
us to the right person who may be able to help us with this.

Thank you,

Eric

Eric Croiset, PEng
Professor
Department of Chemical Engineering
University of Waterloo
Waterloo, ON N2L 3G1
Canada
Tel. (519) 888-4567 x36472
https://uwaterloo.ca/chemical-engineering/people-profiles/eric-croiset

From: Hao Wang <h475wang at uwaterloo.ca<mailto:h475wang at uwaterloo.ca>>
Sent: November 18, 2021 8:35 AM
To: Eric Croiset <ecroiset at uwaterloo.ca<mailto:ecroiset at uwaterloo.ca>>
Cc: John Zhang <m78zhang at uwaterloo.ca<mailto:m78zhang at uwaterloo.ca>>
Subject: Pyinstaller Mac App Crash

Dear Mister/Miss.,

Hi! I would like to ask for help in creating macOS bundles using 
Pyinstaller.

I am currently using Pyinstaller to create macOS bundles of a Tkinter 
GUI in Python. The command I used was: ‘pyinstaller --onefile --windowed 
--name=Shortcut_Distillation_Simulation --icon=./Assets/uwicon.ico 
Distillation_v10_MIP_EW.py’. It generates two files: Application and 
Unix Executable File. When running the Application by double-clicking on 
the icon in Finder, it opens and closes immediately. The Unix Executable 
File runs fine.

Context:
Pyinstaller version: 4.7; Python version: 3.7.3; Platform: macOS 
Monterey 12.0.1

Tried:
I tried to comment out a part of code each time to find the source of 
the problem. I figured out that when commenting out lines shown below, 
the Application and Unix Executable File generated using Pyinstaller 
will both run perfectly. I have attached the package with source code 
and supporting files to this email.
[cid:17d8137263a5b16b21]

Thank you for your help with this matter!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pyinstaller.png
Type: image/png
Size: 45035 bytes
Desc: not available
URL: <http://lists.uwaterloo.ca/pipermail/mactug/attachments/20211203/43d3d3d2/attachment-0001.png>


More information about the MacTUG mailing list