-
Notifications
You must be signed in to change notification settings - Fork 446
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrap --codesign-identity & --add-binary into flet pack #1776
Comments
Clearing any ~.flet cache does resolve the app icon issue when using pyinstaller. The App name when running appears to be the only thing I can't resolve. |
For further testing and to confirm this solution does indeed resolve the issue I explored the source for pack.py and added in the parser argument for --codesign-identity as well as the handler. I officially have a fully signed (end to end) and working macOS app when using "flet pack". I'm new to contributions on github so I'll review the guidelines and make a submission if it's of interest for the repo manager/owner. |
You are absolutely welcome to do a PR, thank you! |
Finally getting time to get around to the PR so I'll do that this afternoon. I'm going to include wrapping for --add-binary as well due to further testing with dynamic linked libraries (.dylib) being packed. Unsigned you can get away with --add-data to pack the dylib in "./" however, with end to end code signing I noticed the underlying security system of macOS was unhappy about the dylib signing. Adding in --add-binary to use for dynamic linked libraries in flet pack resolved this in code signed packages. |
Closing. PR #1789 accepted and merged. |
Please Describe The Problem To Be Solved
In macOS if you pack a .app using "flet pack", and then codesign + notarize the app it will fail to run because the packed binaries are not signed as well. The easy workaround is to use pyinstaller which allows the argument "--codesign-identity" to complete the build with an end to end signing process.
The problem with this workaround appears to be that once the Application is opened the app icon changes to the Flet icon, and the application name changes to "Flet". Meanwhile, the app icon & name remain correct in /Applications.
(Optional): Suggest A Solution
Not sure how feasible or desirable this option fits into the future of the project, but it would be helpful with the current circus of code signing on MacOS.
The text was updated successfully, but these errors were encountered: