How create certificate for my python bundle in xcode or manually?

I have created a python script that does some functions and it is a single file script uses AppKit python library that accesses the pyobjc.

Script is running as expected in my mac system.So I bundled it using PyInstaller package giving a unique bundle identifier as argument that is also fine. The pyinstaller created a build and dist folder and an executable file.

This executable file runs perfectly as expected, in my system in which I have created the package.

When I transfer this bundle to another mac system It doesn't works and creates an error unidentified developer.

Please let me know how to run it on the other system to which I distributed it to?
Hi!

As you're now creating an executable rather than a script you'll need to sign and notarise your binary to allow it to execute on another Mac.

When you transfer the binary to another Mac, your binary is being quarantined and the code signing and notarisation requirement is being enforced by Gatekeeper.

Please take a look at eskimo's excellent guides on signing and distributing outside the App Store, the Apple article on Notarisation and eskimo's article on testing a notarised app. There's also a talk on notarisation from WWDC 2019. These should get you well on your way to securing your pyinstaller binary for distribution.

To create the developer certificate to sign your binary, you'll need to use the developer portal.

If this is just for your own use, and not for distribution to others, this article on Gatekeeper will tell you how to open an application that is not notarised or signed. If you are distributing to others, please sign and notarise.

I hope this helps! I know it can be a lot to take in, so please feel free to ask any additional questions here on the forums!
How create certificate for my python bundle in xcode or manually?
 
 
Q