gon icon indicating copy to clipboard operation
gon copied to clipboard

Notarization result wait process randomly fails with a plist type mismatch error about 5-10% of the time

Open jimeh opened this issue 2 years ago • 2 comments

I have a project that produces nightly builds of Emacs for macOS, and I'm pulling in gon as a Go package to handle the notarization and stapling.

However, every now and then it fails with a plist type mismatch error. It looks like Apple's notarization server sometimes returns some unexpected value.

From the most recent build:

2022-03-05T01:23:23Z [INFO]  notarize: notarizing: file=Emacs.2022-03-04.6ad223f.master.macOS-10-15.x86_64.dmg
2022-03-05T01:23:23Z [INFO]  notarize: submitting file for notarization...
2022-03-05T01:23:46Z [INFO]  notarize: submitted
2022-03-05T01:23:46Z [DEBUG] notarize: request: uuid=f300630d-9fa5-49c8-88cd-7d1a583dc2cd
2022-03-05T01:23:46Z [INFO]  notarize: waiting for result from Apple...
2022-03-05T01:23:58Z [INFO]  notarize: status update: status="in progress"
ERROR: failed to decode notarization submission output: plist: type mismatch: tried to decode plist type `dictionary' into value of type `string'

Despite this error, I still get a confirmation email from Apple telling me that notarization was successful. It normally takes about 10 minutes for Apple to notarize the build, and this error seems to happen randomly at any point throughout the waiting process.

I haven't dug any deeper yet, but figured I'd start reporting it here incase anyone else has seen this issue.

jimeh avatar Mar 05 '22 11:03 jimeh

Seeing same issue. Do we have any workaround for this as the package does get notarized but since process exits with error the notarization process fails.

neha-p6 avatar Jul 11 '22 12:07 neha-p6

@neha-p6 I don't have a workaround yet. But I also haven't looked any deeper into the issue yet. Though re-running my GitHub Action every couple of days when it fails is starting to get quite annoying.

At least GitHub Actions now supports rerunning failed jobs only, so retrying is only 10 minutes worth of notarization for me, rather than re-building the whole app from source again which takes about an hour.

jimeh avatar Jul 12 '22 00:07 jimeh