-
Notifications
You must be signed in to change notification settings - Fork 2
GUI
The GUI will have a place for the user to enter their needed credentials to connect and upload to the CRIPT platform, show a loading screen and progress of what is being uploaded, and an error screen displaying the Excel errors for the user to fix.
Excel uploader original code is located in src/python/ with minimal changes to all files except for what used to be called main.py, that is now refactored into a class called excel_uploader_main.py. All the python files including gui_main.py can use some refactoring to improve them for the future
The package being used to make the GUI is called eel. I am using html, css, bootstrap css, and plain JS to run it in Chrome app mode. The python file that controls the GUI is gui_main.py and all UI code is located in src/web/
For the graphics I am downloading them from undraw.co, and placing them in src/web/assets/
The condensed CRIPT logo used for the executable icon is placed in src/assets/
I am using pyinstaller to compile the code into an executable.
The way that I have used to compile in the past has been with the following steps
- Create and activate virtualenv
python -m venv .\venv
.\venv\Scripts\activate
- install dependencies from
requirements.txt
pip install -r requirements.txt
- compile code to executable
cd .\src\
-
python -m eel .\gui_main.py .\web\ --onefile --noconsole --name excel_uploader_gui_windows --icon=.\assets\logo_condensed.ico
-
Note: If you are compiling multiple times and running into issues, please be sure to clean out anything that might have been cached that could cause issues. You can try clearing Chrome cache, deleting venv and reinstalling dependencies, remove any problematic files or folders from
C:\Users\myusername\AppData\Local\Temp
and using CCleaner
-
- This should create a build/ directory, dist/ directory and an excel_uploader_gui_windows.spec file
- The GUI executable is located in dist/excel_uploader_gui_windows.exe
python -m eel .\gui_main.py .\web\ --onefile --noconsole --name excel_uploader_gui_windows --icon=.\assets\logo_condensed.ico
There is CD that will compile the GUI on 3 different OS (windows, Mac, Ubuntu) and spit out the fully compiled executable as an artifact that can be grabbed and put on the releases page and later linked to in the documentation.
.github/workflows/pyinstaller_gui_mac.yaml
.github/workflows/pyinstaller_gui_ubuntu.yaml
.github/workflows/pyinstaller_gui_windows.yaml