Repository navigation
ci(nightly-next): reuse the compiled nightly app when its inputs did not change - #25731
Conversation
|
Owned by an agent session · session |
|
Bead |
…not change build-nightly-app keys its unsigned app and dSYMs with job_input_fingerprint.py nightly-release-product and reuses a record from an earlier nightly-next push run whose build-nightly-app succeeded, with its SHA-256 checked, in the NIGHTLY_NEXT record namespace (never a DEV record). A hit unpacks the products (bounded, symlink-safe, staged then renamed) and skips every step that only feeds xcodebuild; stamping, signing, notarization and publication always run. A build commit whose nightly.yml differs from the running one never reuses, and every miss clears the products directory. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-cc8bff1c3ddb4ec353c5
…e real filesystem Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-cc8bff1c3ddb4ec353c5
… started before the lookup Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-cc8bff1c3ddb4ec353c5
3d69dd5 to
fc99f07
Compare
Bugbot needs on-demand usage enabledBugbot uses usage-based billing for this team and requires on-demand usage to be enabled. A team admin can enable on-demand usage in the Cursor dashboard. |
|
Review (Codex gpt-6-astra xhigh, independent): SHIP at fc99f07 Re-review after the rebase onto feat-cmux-next (background helper builds, the Linux-built inputs, the early Chromium fetch). No blocking findings: helper starts and joins are gated together, ungated steps need no skipped outputs, packing follows helper and notices bundling and the strip, and PR runs cannot reach the record lookup or upload. |
|
Found 8 test failures on Blacksmith runners: Failures
|
…es what APFS would alias Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-cc8bff1c3ddb4ec353c5
|
cmux status (one comment, edited in place; each line is updated by the job that owns it) Review App of this head (app.zip, kept 1 day)
red: cmux-next checks (god files, concurrency, crash safety, l10n); no finished base run on 7c2a29c to compare; do not merge until green; see lane-rules |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-cc8bff1c3ddb4ec353c5
…icode normalization Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-cc8bff1c3ddb4ec353c5
|
Review (Codex gpt-6-astra xhigh, independent): SHIP at d870732 After three more rounds on the archive checks: they now fold names as APFS does (letter case and Unicode normalization), walk each symlink by exact and by folded name, and refuse collisions before extraction. The Linux CI failure of test_nightly_release_product_reuse.py (case-sensitive volume) is fixed, and the test passes on macOS and on Linux. Codex found no concrete escape or overwrite. |
|
|
|
|
Base gained nightly-next product reuse (#25731). The capture decide step now runs before "Look up the nightly app compiled on the same inputs" and gives it a SKIP_REASON on a capture run, so the compile runs, and the capture starts only on a miss. The capture steps stay last but the cleanup, after the reuse record's upload. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-f6b9335f650995bf635b
|
Shipped in:
|
… handoffs - cmux-next.yml dev-cas-holder records (410d38a, #25744): 7 -> 3 days. A missing record only makes dev-landing-place pick any free owned Mac. - cmux-tui.yml optchat-chief-lock (c1e3804, #21928): 7 -> 3 days; it is a lockfile repair a person reads after a red run. - Allowlisted, same reasons as their already-listed twins: dev-landing-compile's cmux-next-dev-daily-unsigned-<sha> (#25744, the same 2-day handoff cmux-scheme-compile already lists), nightly.yml's cmux-nightly-unsigned-app#3 (the 1-day retry of #2 from #26044), and cmux-nightly-next-release-archive-<sha> (#25731, the 2-day nightly reuse product). Moving them to R2 changes their readers and belongs in its own PR.
… handoffs - cmux-next.yml dev-cas-holder records (410d38a, #25744): 7 -> 3 days. A missing record only makes dev-landing-place pick any free owned Mac. - cmux-tui.yml optchat-chief-lock (c1e3804, #21928): 7 -> 3 days; it is a lockfile repair a person reads after a red run. - Allowlisted, same reasons as their already-listed twins: dev-landing-compile's cmux-next-dev-daily-unsigned-<sha> (#25744, the same 2-day handoff cmux-scheme-compile already lists), nightly.yml's cmux-nightly-unsigned-app#3 (the 1-day retry of #2 from #26044), and cmux-nightly-next-release-archive-<sha> (#25731, the 2-day nightly reuse product). Moving them to R2 changes their readers and belongs in its own PR.
![Fix with [code]smith](https://pr-comments-assets.blacksmith.sh/codesmith/fix-with-codesmith-light-3x.png)
Leo, 2026-10-26: "And I thought we were incremental. You keep saying, yeah, we're gonna do the incremental building. Nobody has come back with the incremental building results." Earlier: "like how fast can we just have it, like hot and incrementally built?... reusing as much as you can".
What this does (2 of 2, on top of #25729)
The cmux NEXT Nightly build (nightly.yml
build-nightly-app, nightly-next push runs) now reuses its compiled, unsigned app when nothing it is built from has changed. The DEV lane already does this (#24963, #24964). This change shares that code instead of copying it.Key. The key is
job_input_fingerprint.py nightly-release-product. It uses the DEV product's closure: the whole tree minus docs, tests and other products. It also keys:nightly.yml;decideoutput the build reads (identity, icon, arches, browser-import flags,password_readers_out);The fingerprint job's name is part of the key, so a nightly key never equals a DEV key.
Records. Reuse runs only for nightly-next push builds that are not fast, build-only or notary tests. A record is taken only from this repository's own
nightly.ymlpush run onnightly-nextwhosebuild-nightly-appfinished successfully. The archive's SHA-256 is checked against the record. Records and archives use their own names (cmux-nightly-next-release-product-*,cmux-nightly-next-release-archive-*). A DEV record is never read as a nightly product, and the reverse never happens either. Pull-request runs cannot write any of this.On a hit. The app and its dSYMs are unpacked into
build-universal/Build/Products/Release. Every step that only feeds xcodebuild is skipped: web bundles, Rust helpers, Chief, mobile host, CEF fetch, notices, xcodebuild, Iroh drop, Computer Use helper, strip. These steps still run on a hit:The version, build number and CMUXCommit are stamped later, in
build-sign-notarize-nightly, so the compiled products name no run. Signing, notarization and publication always run fresh.Recording. After a successful build, the products are packed and recorded with a 2-day retention. A build missing the Chromium engine or the remote browser host (both optional inputs) is never recorded.
Misses. Every problem counts as a miss with a reason, and the job compiles as before. That includes:
ghwait);nightly.ymldiffers from the running one.An unpack is staged and renamed into place, so xcodebuild never merges into a partial app.
vars.CI_NIGHTLY_NEXT_PRODUCT_REUSE=0switches the lookup off.Baseline (before)
Measured with the same harness (
measure_next_build.py --workflow nightly.yml --branch nightly-next --event push --limit 10 --steps). The xcodebuild seconds and cache counts come from each job's log.Risk
Medium. The change touches the shipped nightly's build path, but it is all-or-nothing and content-keyed:
nightly.yml, app sources) and that the skipped steps read no decide output or repository variable outside the key.Signals
nightly-next Release product: **hit**and the build step is skipped. Its later jobs sign, notarize and publish as usual.vars.CI_NIGHTLY_NEXT_PRODUCT_REUSE=0.Tests
tests/test_nightly_release_product_reuse.py(new) covers:..and absolute paths, symlink chains, case-insensitive aliasing, members under a link, duplicates, oversized PAX headers, member and byte bounds;tests/test_nightly_release_product_key.py).tests/test_gh_budget_wait.py(the lookup makes noghcall) and.github/nightly-step-coverage.json.Agent session: agent session
🤖 Generated with Claude Code
Need help on this PR? Tag
@codesmith-botwith what you need.