-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Builder fails somewhat randomely #4098
Comments
I feel like I'm clutching at straws here but something I noticed is that all builds that starts with signing The above worked after trying yarn add electron/electron-builder. I did that without removing the packages so nothing should have change. EDIT: Tried downgrading to 21.0.3 because of a removed comment. Gives me Unnotarized Developer Id rejection which is a much better dialogue than what I've been receiving. I thought notarizing was a step to be done later after I get the build stabilized so I've been pushing my debugging away from it. Will look into and see |
Downgraded to version Running
Running latest ( I do not know entirely what this means for my project but this seems like a more consistent problem to tackle. Leaving the issue open as the original question still stands as to why my builds on latest were so inconsistent (whether the app was notarized or not). |
We're getting this too with the same message with v21.2.0 |
@alibosworth I was not able to resolve my original issue but I followed these 2 issues to create a working PKG for putting my app on the macOS App Store. I downgraded my Electron to 5.0.7, followed the video to get a base working project, modified it, then manually signed it with the script sign-mas.sh in the link above. Hope that helps a bit. |
Thanks @anl176, we seem to be able to have everything work properly (building and signing) by downgrading to electron-builder 21.0.15 (with Electron 5.0.3). |
Actually, unfortunately while downgrading to 21.0.15 lets the MAS build work, it breaks the signing of the MAC build so we are kind of stuck, because 21.2.0 works for the MAC build but not the MAS one. |
I am experiencing the same issue, after trying to notarize an app which requires me to update to electron-builder |
i am having the same issues too... |
Any updates on this? |
I am having the same problem on 21.2.0. I can get it to build successfully by running my build command with sudo, but this causes all sorts of issues, too many to go into in a single post. |
Any update on this? Has anyone been able to successfully notarize an Electron App? |
+1 Same issue here |
I am facing the same issue. Any update on this? |
@muhzi4u There is no update, but I found a workaround. When building a MAS build, don’t pass an array into your “target”, only do “target”: “mas”. Passing additional items into the target is what’s causing the error. As long as mas is the only target it no longer fails for me. |
Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward? This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. |
Problem:
Building for mas usually fails
Sometimes build works after I make "some" kind of modification like changing entitlements or reinstalling my dev provisioning profile. Running build after a success fails even though no files were modified.
For reference, I've been following this guide: https://samuelmeuli.com/blog/2019-04-09-publishing-an-electron-app-on-the-mac-app-store/.
I generated all macOS certs through xCode and have them in my KeyChain
and created a dev provisioning profile to match my device.
I tried recreating all my certs/profiles, taking out entitlements until it was either empty or just sandbox and following the linked guide as closely as possible. Sometimes the build works but never twice in a row and usually replicating what I did to get the build working does not work.
I am completely new to Electron with very little experience in the Apple Development Ecosystem so I included as much detail as possible below. I suspect it's something like my entitlements or certs being wrong. For example, I have entitlements for push notifications but did not turn that on in my app's identifier capabilities. Then again, I got it building once by just removing entitlements
<key>com.apple.application-identifier</key>
up to the line<!-- Receive push notifications for macOS -->
Maybe bonus clue is when a build is successful and I try to run my app in
build/dist/mas/MyApp.app
it fails with theEXC_BAD_ACCESS (Code Signature Invalid)
Exception. I run my code through VS Code if that matters. Many thanks and sorry for wall of text.snippet of package.json
build/entitlements.mas.plist
Relevant root file structure
What a success looks like
The text was updated successfully, but these errors were encountered: