Repository navigation
ci: save caches only from main and keep the iOS release archive recoverable - #563
Merged
Merged
Conversation
The repository's Actions cache holds 11.56 GB in 19 entries against the 10 GB limit, so GitHub keeps evicting the least recently used entries. Only 5.5 GB belongs to main. The rest was written by manual runs on development branches (3.5, 1.06 and 0.48 GB this week) and by a release tag (0.44 GB). A cache saved on a branch or tag can only be restored by that same ref, so those entries serve almost nothing while they push out main's caches, and every branch then starts from a cold or partial build. Nine rust-cache steps saved on main or any workflow_dispatch, including release dispatches on tags. Eight rust-cache steps and the Chromium cache had no save condition, so release tags, the merge queue and branches all wrote. The simulator app cache saved on any ref. Every rust-cache step now saves only on refs/heads/main; other refs keep restoring main's caches. Chromium uses restore plus a main-only save, and the simulator app saves only on main. Manual-only workflows now start from main's caches, and are cold until they have run on main once.
…ifact Recovering a failed product release reruns its publishers from the original producer artifacts, and the Nightly coordinator refuses a recovery once any of them has expired. Every producer artifact uses the repository's 90-day retention except the iOS device archive, which set 14 days. A failed release left alone for two weeks could then never be recovered, and the coordinator keeps selecting it until an abandonment lands on main. Use the default retention for the iOS archive as well.
# Conflicts: # .github/workflows/release-desktop.yml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The repository's Actions cache holds 11.56 GB in 19 entries, above the 10 GB limit, so GitHub keeps evicting the least recently used entries. Measured 2026-11-13:
main(9 entries)fix/update-release-discovery(manual CI for #562)fix/iphone-lan-message-deliveryfix/release-desktop-arm64-oom(#561)v0.0.1-nightly.20261112.2A cache saved on a branch or tag is restorable only by that same ref. Those entries serve almost nothing, but they push out main's caches, so main and every branch fall back to cold or partial builds.
Causes:
Swatinem/rust-cachesteps saved ongithub.ref == 'refs/heads/main' || github.event_name == 'workflow_dispatch'. That covers any manual run on any branch or tag, including the release runs the Nightly coordinator dispatches on tags.rust-cachesteps (release, mobile, GPUI feature check, native diagnostics) and the Chromiumactions/cachehad no save condition, so release tags, merge-queue refs and branches all wrote.Separately, the iOS device archive was the only producer artifact with
retention-days: 14; the repository default for all the others is 90. Publisher recovery needs every original producer artifact, so a failed product release left for two weeks could never be recovered. The Nightly coordinator would keep selecting it until an abandonment landed on main.Still true on 2026-11-13 after #569: 18 entries, 11.2 GB.
Change
Swatinem/rust-cachesteps in the remaining workflows usesave-if: ${{ github.ref == 'refs/heads/main' }}. These are inci.yml,_ci-crypto.ymland the release producers (release.yml,release-native.yml,release-desktop.yml,release-ios.yml,release-apps.yml). Other refs, including release tags and manual branch runs, still restore main's caches by key prefix but never write their own.release-ios.ymldrops the 14-day override, so the iOS device archive gets the default retention like every other producer artifact. This is a separate commit.Updated onto main after #568 (e2e removed from Actions) and #569 (non-core workflows removed):
ci-desktop.yml,ci-windows-native.yml,ci-native-diagnostics.ymlandmobile.ymlare dropped.actions/cacheremains.Trade-offs
setup-nodewithcache: pnpmis unchanged. It writes only on a lockfile miss (about 200 MB) and has no save condition.Validation
rust-cachesteps carry the main-only condition and that no combinedactions/cacheremains.python3 scripts/ci.py --self-test,python3 -B scripts/check-release-workflow.py --self-testand the real check,scripts/release.py self-test, andscripts/hourly.py --self-test.actionlintin "Workflow and source checks".