Can't run my signed & notarized app in macOS Catalina

Hi all,


After some trouble, I have managed to get my app signed and notarized. However, when testing the .dmg installer in another computer (running macOS Catalina), it fails to run - the splash screen appears at the beggining and then the app just closes.


My app is built on Electron 4.0.6 and uses both Python (backend) and javascript (frontend), which communicate over a websocket (which is initialised in the splashscreen). My app reads and writes files from a folder in Documents (config files) and also reads and saves files through user input. Furthermore, my app performs acquisitions over Bluetooth and USB, and uses the user's location.


I have been using the following entitlements (entitlements.mac.plist) for signing entitlements and entitlementsInherit:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>com.apple.security.cs.allow-jit</key><true/>
    <key>com.apple.security.cs.allow-unsigned-executable-memory</key><true/>
    <key>com.apple.security.cs.disable-library-validation</key><true/>
    <key>com.apple.security.automation.apple-events</key><true/>
    <key>com.apple.security.temporary-exception.files.absolute-path.read-only</key><true/>
    <key>com.apple.security.temporary-exception.files.absolute-path.read-write</key><true/>
    <key>com.apple.security.network.client</key><true/>
    <key>com.apple.security.network.server</key><true/>
    <key>com.apple.security.assets.movies.read-write</key><true/>
    <key>com.apple.security.assets.music.read-write</key><true/>
    <key>com.apple.security.assets.pictures.read-write</key><true/>
    <key>com.apple.security.files.downloads.read-write</key><true/>
    <key>com.apple.security.files.user-selected.read-write</key><true/>
    <key>com.apple.security.device.usb</key><true/>
    <key>com.apple.security.device.bluetooth</key><true/>
    <key>com.apple.security.personal-information.location</key><true/>
</dict>
</plist>

To run the signing I use the following command:

./node_modules/.bin/electron-osx-sign dist/MyApp.app --no-gatekeeper-assess --identity="Developer ID Application: COMPANY (#######)" --entitlements=dist/entitlements.mac.plist --entitlementsInherit=dist/entitlements.mac.plist


Afterwards, I sign all the files with extension .so, .dylib, .a and .o using XCode command:

codesign --sign "Developer ID Application: COMAPNY (########)" \
                 --entitlements dist/entitlements.mac.plist \
                 --deep filename \
                 --force \
                 --timestamp \
                 --options runtime;


Any clues of what is wrong? Unfortunately I don't know how to gather information on the error that macOS is throwing - I just see my app closing suddenly.


Many thanks,

Diogo

Replies

It’s almost certain that your app has crashed. You should run the Console app, select Crash Reports on the left, and see if there’s a crash report.

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"

Many thanks for your fast reply, eskimo!


You can find the output here: https://imgur.com/a/32ZjSwK . No crash appeared, but I got these messages. Any clues?