Skip to content

Restore PR build cache parity#526

Merged
AnthonyRonning merged 1 commit into
masterfrom
restore-pr-build-cache-parity
May 20, 2026
Merged

Restore PR build cache parity#526
AnthonyRonning merged 1 commit into
masterfrom
restore-pr-build-cache-parity

Conversation

@AnthonyRonning
Copy link
Copy Markdown
Contributor

@AnthonyRonning AnthonyRonning commented May 20, 2026

Summary

  • restore missing PR build caches for Tauri CLI, sccache, Gradle, Bun, Homebrew, and Xcode where they match the signed build workflows
  • add a master-only iOS simulator ONNX cache warmer so new PR branches can restore the simulator ONNX cache from the default branch
  • keep PR builds unsigned and without signing secrets

Why

PR iOS builds were paying a cold ONNX source build because the simulator ONNX cache is only created in pull_request scope. GitHub does not make a cache created for one PR branch generally available to future PR branches, so this would recur. The new warmer creates the same simulator cache key on master, where future PRs can restore it.

Validation

  • workflow YAML parsed with Bun + yaml
  • git diff --check
  • checked workflow-only diff and checkout credential settings
  • pre-commit hook: Prettier, frontend build, Bun tests

No package versions, dependencies, or lockfiles changed.

Summary by CodeRabbit

  • Chores
    • Added sccache and expanded caching across Android and desktop (macOS/Linux) CI to speed Rust builds and report cache stats.
    • Added verification and pinned installs for build tooling and expanded caching of tool binaries to stabilize CI.
    • Added a warm iOS simulator ONNX Runtime cache job to reduce PR rebuilds.
    • Moved Xcode setup earlier and unified Homebrew cache keys to improve cache reuse in mobile workflows.
    • Updated Android/Gradle cache keys and made Tauri CLI installs version-gated in CI and release workflows.

Review Change Stack

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 20, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

This PR improves CI build performance by adding Bun/Gradle/Homebrew caches, installing and configuring sccache for Android/desktop builds, adding a warm iOS ONNX Runtime simulator cache job, and aligning mobile Homebrew cache keys.

Changes

Build Performance Optimization via Strategic CI Caching

Layer / File(s) Summary
Android build acceleration: Bun and Rust caching
.github/workflows/android-pr-build.yml
Adds Bun dependency caching and Gradle caches/wrapper caching; installs a pinned sccache release (with checksum), caches sccache and ~/.cargo/bin for a pinned Tauri CLI, and configures RUSTC_WRAPPER/SCCACHE_DIR/SCCACHE_CACHE_SIZE=2G in GITHUB_ENV.
Desktop macOS & Linux build acceleration: sccache
.github/workflows/desktop-pr-build.yml, .github/workflows/desktop-build.yml
macOS: caches Homebrew artifacts, installs/links sccache via Homebrew, caches Mozilla sccache directory, and sets sccache env vars; Linux: downloads/verifies pinned sccache tarball, caches ~/.cache/sccache and ~/.cargo/bin, and prints sccache --show-stats after builds.
iOS ONNX Runtime simulator artifact caching & Homebrew key alignment
.github/workflows/mobile-build.yml, .github/workflows/mobile-pr-build.yml
Repositions Setup Xcode earlier in iOS builds, adds warm-ios-pr-onnx-cache job to warm ONNX Runtime simulator artifacts (builds on cache miss and verifies the .xcframework), and switches mobile PR Homebrew cache keys from PR-scoped to shared keys.
Tauri CLI version-gated install
.github/workflows/android-build.yml, .github/workflows/release.yml, .github/workflows/desktop-build.yml, .github/workflows/mobile-build.yml, .github/workflows/mobile-pr-build.yml, .github/workflows/android-pr-build.yml
Standardizes installing tauri-cli v2.9.2 by detecting cargo-tauri --version and only running cargo install tauri-cli --version ... --locked --force when the installed version differs; otherwise logs the required version is present.
Gradle cache key path updates
.github/workflows/android-build.yml, .github/workflows/release.yml
Updates Gradle cache hashFiles to use frontend/src-tauri/gen/android/gradle/wrapper/gradle-wrapper.properties to change when Gradle wrapper cache is invalidated.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Poem

🐰 Bun cached snug, sccache set to spin,
Xcode ready early, ONNX warmed within,
Gradle keys tuned, caches shared with care,
CI hops lighter through the build-room air,
a rabbit cheers — swift runs everywhere!

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'Restore PR build cache parity' directly and specifically summarizes the main objective of the changeset, which is to restore missing PR build caches across multiple CI/CD workflows to match the signed build workflows.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch restore-pr-build-cache-parity

Comment @coderabbitai help to get the list of available commands and usage tips.

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented May 20, 2026

Deploying maple with  Cloudflare Pages  Cloudflare Pages

Latest commit: 03aba1e
Status: ✅  Deploy successful!
Preview URL: https://d15691e7.maple-ca8.pages.dev
Branch Preview URL: https://restore-pr-build-cache-parit.maple-ca8.pages.dev

View logs

coderabbitai[bot]

This comment was marked as resolved.

@AnthonyRonning AnthonyRonning force-pushed the restore-pr-build-cache-parity branch from 24e8254 to f920232 Compare May 20, 2026 21:48
coderabbitai[bot]

This comment was marked as resolved.

@AnthonyRonning AnthonyRonning force-pushed the restore-pr-build-cache-parity branch 2 times, most recently from 2c1b565 to 8734695 Compare May 20, 2026 21:55
coderabbitai[bot]

This comment was marked as resolved.

@AnthonyRonning AnthonyRonning force-pushed the restore-pr-build-cache-parity branch from 8734695 to 03aba1e Compare May 20, 2026 22:04
coderabbitai[bot]

This comment was marked as resolved.

Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 4 additional findings.

Open in Devin Review

@AnthonyRonning AnthonyRonning merged commit b57b967 into master May 20, 2026
12 checks passed
@AnthonyRonning AnthonyRonning deleted the restore-pr-build-cache-parity branch May 20, 2026 22:17
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