Closed andyoknen closed 2 years ago
Same problem here. Worked great with macos-10.15
but fails to notarize using macos-latest
or macos-12
. And since macos-10.15
is now deprecated, I am no longer able to notarize my app using Github Actions.
UPDATE
Switching to authenticate with username and password (APPLE_ID
and APPLE_ID_PASSWORD
) instead of API_KEY
has resolved the issue for me. Updated my build.yml as follows:
env:
APPLE_ID: ${{ secrets.apple_id }}
APPLE_ID_PASSWORD: ${{ secrets.apple_id_password }}
where
APPLE_ID
String - The username of your apple developer account
APPLE_ID_PASSWORD
String - The app-specific password (not your Apple ID password)
I have exactly the same issue :(
Even by putting APPLE_ID
and APPLE_ID_PASSWORD
, I still have the issue.
I'm not sure which of these helped me, but this configuration signs my code and notarizes successfully
- name: Prepare for app notarization
run: |
mkdir -p ~/private_keys/
echo '${{ secrets.APPLE_API_KEY }}' > ~/private_keys/AuthKey_${{ secrets.APPLE_API_KEY_ID }}.p8
echo '${{ secrets.APPLECERT }}' | base64 -d > applecert.p12
- name: Building
env:
APPLEID: ${{ secrets.APPLEID }}
APPLEIDPASS: ${{ secrets.APPLEIDPASS }}
API_KEY_ID: ${{ secrets.APPLE_API_KEY_ID }}
API_KEY_ISSUER_ID: ${{ secrets.APPLE_API_KEY_ISSUER_ID }}
CSC_LINK: 'file://applecert.p12'
CSC_KEY_PASSWORD: ${{ secrets.APPLECERTPWD }}
Maybe the problem is not here - but I hope for help, because I can't find a solution yet. Thanks!
⨯ The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Error failedTask=build stackTrace=TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Error
@andyoknen the error handling part in the package is throwing this error. You are not able to see the actual error due to this.
I'll submit a PR with the fix.
@juli1 thanks! Would love to have more information about what is going on!
@andyoknen do you still use samuelmeuli/action-electron-builder@v1
? Do you mind sharing your entire configuration?
Thanks,
@andyoknen do you still use
samuelmeuli/action-electron-builder@v1
? Do you mind sharing your entire configuration?
I'm sorry, I mixed up the workflow - in the example above, I use electron-builder to build. Here is my action to build the release now - it looks like everything is fine with it now. I think I fixed the notarization for a long time, but I don't remember exactly how :)
https://github.com/pocketnetteam/pocketnet.gui/blob/master/.github/workflows/build.release.yml
I think the issue can be closed - my question is exhausted
This problem only shows up if I use GitHub Actions I have now checked the build according to the instructions from this repository - everything works Maybe the problem is not here - but I hope for help, because I can't find a solution yet. Thanks!
I followed these instructions https://github.com/samuelmeuli/action-electron-builder#notarization https://samuelmeuli.com/blog/2019-12-28-notarizing-your-electron-app
My build.yml: