Open Bug-Reaper opened 2 months ago
I was able to notarize my DMG/App manually via notarytool which confirms this appears to be a forge error.
Hi @Bug-Reaper, thanks for the confirmation! I found an Apple Developer Forum thread that seems to point out that this might be a problem with the size of the app and how we compress it in @electron/notarize
with ditto
:
According to a second Apple Developer Forum thread, there are a few workarounds listed (including moving off of ditto
), but the official solution seems to be to upgrade to XCode 15.
Do you know what XCode version you're running?
Also moved this issue into the correct upstream repo :)
Hey @erickzhao thanks for moving me around.
Just to clarify I don't think the size of my DMG was an issue. More-so that electron-forge tried to notarize it from a tmp folder before it was finished copying or something like that (thus we get the malformed zip file error)?
When I built the DMG w/no notarization via forge it built fine and I was able to manually notarize via xcrun notary-tool
no issue. Something appears awry with the automatic notary action built into forge.
Again this doesn't appear to be apple-tools failing but :
Xcode 14.1
Build version 14B47b
Pre-flight checklist
Electron Forge version
7.4.0
Electron version
29.X
Operating system
Ventura 13.5
Last known working Electron Forge version
N/A
Expected behavior
App Gets Notarized
Actual behavior
Hard crashes on a notary step:
Steps to reproduce
This is the forge.config.js I was using, it's practically vanilla.
Personal Debug Notes
I'm doing this on an M1 Macbook Pro using
electron-forge make
.osxNotarize:{}
from config.Doesn't appear to be a malformed path -- I forced a thrown error from
@electron/notarize/lib/notarytool.js
to get the array used to execute thenotarytool
command and the result is below.Conclusion
My best guess at this point is the forge is trying to send it for notarization before it's fully copied into tmp storage or is otherwise causing the file to be malformed. It is a rather beefy app (~4Gib). Happy to assist if I have time w/a PR to fix.