Skip to content

fix(signing): send the app to the notary service as a disk image when it refuses the signed zip (0.12.1 backport of #31848) - #34129

Merged
bolichen97 merged 1 commit into
release/0.12.0from
hotfix/0.12.1-notarize-image
Nov 9, 2026
Merged

bolichen97 merged 1 commit into
release/0.12.0from
hotfix/0.12.1-notarize-image

Conversation

@bolichen97

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: Let the 0.12.1 release build notarize the universal macOS app, by backporting main's #31848 to release/0.12.0.

The v0.12.1-rc.2 Release run (42672343465) failed only in Sign + Notarize macOS / Notarize + staple: notarytool refused the universal app's signed zip before any upload ("signed.zip must be a zip archive (.zip), flat installer package (.pkg), or UDIF disk image (.dmg)") on all 3 attempts. The zip is now 1,084,177,868 bytes; v0.12.0-rc.10's was 1,007,118,449 bytes and notarized fine. The arm64-only and x64-only builds notarized and published.

Why it matters

Without it the 0.12.1 Release run cannot finish, so stable-gate has no successful v0.12.1 run and the bare v0.12.1 tag cannot ship.

Not a goal

  • No product code change: CI and packaging scripts only.
  • No change to signing, stapling or the Gatekeeper gate.

What changed (motivation → approach → change)

git cherry-pick -x of main's e94281a (#31848), clean: when notarize.sh sees notarytool refuse the file itself (exit 64), sign-and-notarize.yml wraps the signed app in a disk image (notarize-image.sh) and notarizes that instead; Apple notarizes it in full and the app's ticket staples as before.

Backwards compatibility

Compatible: the zip path is tried first, unchanged; the disk image is only a fallback.

Removes nothing.

Tests

Proof: not provable -- other: a clean cherry-pick of main's #31848, proven in its own main PR; the Release run of the next RC tag is the verification.

Manual verification

N/A: verified by the next RC's Release run.

Related Issues

Part of the 0.12.1 hot patch (#33974, #34032, #34021, #34033, #34035).

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

Contribution License Agreement

Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.

… it refuses the signed zip (#31848)

The universal app's signed zip was refused by notarytool ("must be a zip
archive", exit 64) before anything was uploaded, and notarize.sh retried the
same refusal three times. A probe on the CI runner image showed notarytool
accepts well-formed zips of 94,000 entries, so the signed file itself is
malformed in a way the job log did not show.

notarize.sh now exits 64 at once instead of retrying. The workflow then runs
notarize-image.sh, which logs what the zip is (size, first bytes, end record
fields, entries) and submits an unsigned disk image of the unpacked app, which
Apple notarizes in full. Staple and the Gatekeeper gate are unchanged.

Co-authored-by: w <w@k.local>
(cherry picked from commit e94281a)
@bolichen97
bolichen97 requested review from a team and KiroCrewCaptain as code owners November 9, 2026 21:26
@bolichen97
bolichen97 requested review from CrysisDeu and removed request for a team November 9, 2026 21:26
@bolichen97
bolichen97 merged commit 156cb2e into release/0.12.0 Nov 9, 2026
16 of 19 checks passed
@bolichen97
bolichen97 deleted the hotfix/0.12.1-notarize-image branch November 9, 2026 21:26
@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ⏭️ skipped

Revision f6b431388d7e091a74c66ef705a2d4d1662aff25 touches no user-facing surface (no changes under website/ or committed screenshots), so the UX review was skipped. Does not block merge.

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of f6b431388d7e091a74c66ef705a2d4d1662aff25 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

Nothing blocks: this is a clean backport of #31848 from main. The zip path still runs first, and the disk-image fallback only runs on notarytool's exit 64, with staple and the Gatekeeper gate unchanged.

Notes

  • The fallback's first real run on this branch will be the next RC's Release run. If the image is refused too, the step fails with the inspection log, so a failed attempt is easy to diagnose and costs only a rerun.

[DESIGN-REVIEWED] f6b4313

Description read

[DESCRIPTION-READ] 69cd08155700d8e3c74b70679387369629e28ce19007ff5f3e8855b05dabba6a

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of f6b431388d7e091a74c66ef705a2d4d1662aff25 — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

First-Principles-Verdict: PASS

This is a clean backport of #31848, which is already on main. It fixes a release-blocking notarization failure that has a named Release run, and every item is scoped to that failure.

What this change ships

Inventory (6 items) — 5 justified

Intent: let the 0.12.1 release build notarize the universal macOS app, so the bare v0.12.1 tag can ship. This is a FIX.

  1. When notarytool refuses the file before uploading it (exit 64), notarize.sh stops at once instead of retrying — justified
  2. When the signed zip is refused, the notarize step sends the same app to Apple as a disk image; the zip is still tried first — justified
  3. The fallback logs what the zip is (size, first bytes, end-record fields, whether a zip64 locator is present) before imaging it — undeclared, only writes to the log
  4. The temporary image is kept in work/notarize-scratch and deleted afterwards, so it never ends up as a shipped work/*.dmg — justified
  5. The signing runbook and packaging/signing/README.md describe the exit-64 path — justified
  6. Drills cover the exit-64 no-retry and the image script; test_notarize_budget now runs from tmp_path — justified

[FIRST-PRINCIPLES-REVIEWED] f6b4313

Description read

[DESCRIPTION-READ] 4e506dbbc8898503256741cccf4fab1de07314c4360cae6b39b24ce4d007319f

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed f6b431388d7e091a74c66ef705a2d4d1662aff25 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] f6b4313

Verdict parsed from the review's SHA-scoped output markers for commit f6b431388d7e091a74c66ef705a2d4d1662aff25.

False positive or not applicable? A repository writer can comment:
/ai-review override fable f6b431388d7e091a74c66ef705a2d4d1662aff25 false-positive: <reason, 20 to 500 characters>

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of f6b431388d7e091a74c66ef705a2d4d1662aff25 and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] f6b4313

False positive or not applicable? A repository writer can comment:
/ai-review override gpt f6b431388d7e091a74c66ef705a2d4d1662aff25 false-positive: <reason, 20 to 500 characters>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant