action-electron-builder
action-electron-builder copied to clipboard
Can't notarize application: alttool is deprecated and notarytool not found
Hi,
I'm seeing the following error when using this action to release on Mac:
• signing file=dist/mac/Buttercup.app identityName=Developer ID Application: <snip> identityHash=<snip> provisioningProfile=none
notarytool not found, trying legacy.
📦 Start notarizing <snip> found at /Users/runner/work/buttercup-desktop/buttercup-desktop/dist/mac/Buttercup.app
⨯ ❌ Notarization Error,please check notarization-error.log failedTask=build stackTrace=Error: ❌ Notarization Error,please check notarization-error.log
at module.exports (/Users/runner/work/buttercup-desktop/buttercup-desktop/node_modules/electron-builder-notarize/index.js:101:9)
at MacPackager.doSignAfterPack (/Users/runner/work/buttercup-desktop/buttercup-desktop/node_modules/app-builder-lib/src/platformPackager.ts:332:7)
at MacPackager.doPack (/Users/runner/work/buttercup-desktop/buttercup-desktop/node_modules/app-builder-lib/src/platformPackager.ts:314:7)
So it seems like it's using the older tool. I'm using the latest macos version, so I'm not sure what's wrong. You can see my entire build config here: https://github.com/buttercup/buttercup-desktop/blob/eb31dfca9014eb99151441e35386e8f6c850a546/.github/workflows/build.yml
notarytool
is found however, at: /Applications/Xcode_14.2.app/Contents/Developer/usr/bin/notarytool
, so I'm not sure what's going wrong here.
Contents of notarization-error.log
:
Failed to upload app to Apple's notarization servers
2024-03-28 08:42:14.553 *** Error: Notarization failed for '/var/folders/h1/8hndypj13nsbj5pn4xsnv1tm0000gn/T/electron-notarize-lZEw0g/Buttercup.zip'.
2024-03-28 08:42:14.554 *** Error: Notarization of MacOS applications using altool has been decommissioned. Please use notarytool. See: https://developer.apple.com/documentation/technotes/tn3147-migrating-to-the-latest-notarization-tool With error code STATE_ERROR.NOTARIZATION_UNAVAILABLE for id eb99c3c0-5df4-449a-8d22-75a299c9618e Notarization using altool has been decommissioned (-19208)
{
NSLocalizedDescription = "Notarization of MacOS applications using altool has been decommissioned. Please use notarytool. See: https://developer.apple.com/documentation/technotes/tn3147-migrating-to-the-latest-notarization-tool With error code STATE_ERROR.NOTARIZATION_UNAVAILABLE for id eb99c3c0-5df4-449a-8d22-75a299c9618e";
NSLocalizedFailureReason = "Notarization using altool has been decommissioned";
}
2024-03-28 08:42:14.554 *** Warning: Notarization of MacOS applications using altool has been decommissioned. Please use notarytool. See: https://developer.apple.com/documentation/technotes/tn3147-migrating-to-the-latest-notarization-tool (-1030)
I am also running into the same issue. Seemingly out of nowhere.
I'm also experiencing this. notarytool
is installed on my machine as well. But [action-electron-builder](https://github.com/samuelmeuli/action-electron-builder)
cannot utilize it.
Update
The issue is fixed by passing the below new set of credentials instead to facilitate with notarytool
inputs:
- APPLE_API_KEY
- APPLE_API_KEY_ID
- APPLE_API_ISSUER