Repository navigation
ci(desktop): pin ship Xcode and fail closed on compiler-gated APIs - #13564
Merged
Merged
Conversation
There was a problem hiding this comment.
All reported issues were addressed across 12 files
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
Git-on-my-level
added a commit
that referenced
this pull request
Sep 12, 2026
…full lane Measured on run 34687313733 (PR #13564): with the pin moved to Xcode 26.6, every cache cold under the new xcode266 keys, the full Swift suite ran past 55 minutes and the 60-minute job ceiling cancelled the job mid serial-cluster. Every completed suite was green (one wedged batch cost 1650s before its 1500s watchdog bisected it cleanly; zero test failures) — purely a timing ceiling, so: - desktop-swift-verify timeout-minutes 60 -> 90 - full-lane OMI_SWIFT_TEST_STEP_BUDGET_SECONDS 2700 -> 4200 Both changes cite the run; contract test constants updated to match.
PR #12867 looked right on a local Xcode 26 named bundle and shipped the icon-less system Picker fallback: Liquid Glass sat behind #if compiler(>=6.2) while desktop CI (GHA desktop-swift-ci.yml and Codemagic omi-desktop-swift-release/-preview) compiled with Xcode 16.4, so the ship toolchain never typechecked the glass APIs (#13548 reverted the tab bar). Bump the desktop ship/CI toolchain off 16.4 and make drift impossible: - desktop/macos/ci/xcode-pin.json is now the only place the version (26.6), build (17F113), and expected app path (/Applications/Xcode_26.6.app) live. 26.6/17F113 exists on both vendors: GHA macos-26 image 20260907.0351.1 (default Xcode, /Applications/Xcode_26.6.app) and Codemagic mac_mini_m4 image 'Xcode 26.6.x (default)' (/Applications/Xcode-26.6.app). - run-swift-ci.sh reads the pin file (fails closed when it is missing) and keeps asserting the exact version+build after selection. - desktop-swift-ci.yml macOS jobs move macos-15 -> macos-26, cache key prefixes move xcode164 -> xcode266 so 16.4 caches cannot poison 26.x builds, and the select steps name the pinned version. - codemagic.yaml omi-desktop-swift-release/-preview move xcode: 16.4 -> 26.6 (Android 16.4 and iOS 26.0.1 untouched); the reviewed codemagic_workflow_contract digests are refreshed for that edit. - test_desktop_swift_ci_contract.py loads the pin file instead of literals and adds codemagic pin-agreement + macos-26 runner assertions. Verified locally: bash desktop/macos/tests/test-run-swift-ci.sh (pin 26.6/17F113 sandbox incl. wrong-version/wrong-build/missing-pin sabotage); python3 .github/scripts/test_desktop_swift_ci_contract.py (38 tests OK); python3 .github/scripts/check-release-process-guards.py (exit 0); xcrun swift build -c debug --package-path Desktop on Xcode 26.6 (17F113) completes (1855s).
New desktop-compiler-gates manifest check: desktop/macos/scripts/ check-desktop-compiler-gates.py fails when Desktop/Sources or Desktop/Tests contain #if compiler(...) / #elseif compiler(...) — the shape that let #12867 compile Liquid Glass out of the Xcode 16.4 ship toolchain while CI stayed green (#13548 reverted the tab bar). Runtime availability gating (if #available(macOS 26, *) with a working fallback) is the sanctioned pattern and passes. The allowlist ships empty and is asserted by exact contents in test_check_desktop_compiler_gates.py, so it cannot silently grow; entries require a documented reason and a matching path+line. checks-manifest.yaml also extends desktop-swift-ci-contract triggers with the pin file, runner script, launcher test, and codemagic.yaml so every pin consumer re-runs the contract test on drift. Verified locally: python3 .github/scripts/test_check_desktop_compiler_gates.py (9 tests OK — planted #if compiler(>=6.2) glassEffect sabotage fails the checker and removing it passes); python3 desktop/macos/scripts/ check-desktop-compiler-gates.py on the real tree reports none found; make preflight manifest lane: all selected checks pass except the pre-existing loaded-host flake in test_pr_preflight.py SingleFlightTests.test_identical_processes_join_and_execute_once, which fails 3/3 on pristine origin/main at the same host load (passes in isolation) and is unrelated to this diff.
The desktop changelog check requires an in-repo fragment for production desktop paths even with the no-changelog-needed label: the label is invisible after merge and would redden main's Release Eligibility run. This PR is CI/infra only (toolchain pin + fail-closed gate), so the marker is kind: none.
…full lane Measured on run 34687313733 (PR #13564): with the pin moved to Xcode 26.6, every cache cold under the new xcode266 keys, the full Swift suite ran past 55 minutes and the 60-minute job ceiling cancelled the job mid serial-cluster. Every completed suite was green (one wedged batch cost 1650s before its 1500s watchdog bisected it cleanly; zero test failures) — purely a timing ceiling, so: - desktop-swift-verify timeout-minutes 60 -> 90 - full-lane OMI_SWIFT_TEST_STEP_BUDGET_SECONDS 2700 -> 4200 Both changes cite the run; contract test constants updated to match.
Match compiler() anywhere in #if/#elseif, ignore block-commented directives, and fail closed when the scan root has no Swift files.
#13570 added dueStartDate/dueEndDate to ActionItemsFetcher on main. GitHub analyzes the merge of this PR, so the existing test stubs must accept those named args or Dart Analyze fails.
Git-on-my-level
force-pushed
the
ci/desktop-ship-xcode-pin
branch
from
September 12, 2026 23:05
fd3238b to
8be3ef9
Compare
CI Check Dart formatting uses --line-length 120 after pub get.
…-pin # Conflicts: # .github/checks-manifest.yaml # .github/scripts/test_desktop_swift_ci_contract.py # .github/workflows/desktop-swift-ci.yml # desktop/macos/scripts/run-swift-ci.sh
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.
Closes SCA-467
Product invariants affected
Path-based (codemagic.yaml matched); this PR changes only the two desktop Swift workflows' Xcode toolchain selection — no routing, identity, or auth behavior changes:
INV-AUTH-1
INV-DATA-1
INV-BETA-1
CI budget bump (measured): the first pinned-Xcode 26.6 full lane on
macos-26(run 34687313733) was cancelled by the old 60-minute job ceiling mid-serial-cluster with every completed suite green (one wedged batch cost 1650s before its designed bisect recovered; zero test failures).desktop-swift-verifyceiling 60 → 90 min and the full-lane step budget 2700 → 4200s, both citing that run.Failure-Class: none
Why
PR #12867 (Liquid Glass tab bar) looked fine on a local Xcode 26 named bundle and shipped the icon-less system
Pickerfallback. Root cause: the glass APIs sat behind#if compiler(>=6.2), while every ship lane compiled with Xcode 16.4 — GitHub Actions desktop CI (macos-15,Xcode_16.4.app) and Codemagicomi-desktop-swift-release/omi-desktop-swift-preview(xcode: 16.4) — so the ship toolchain never typechecked the glass code and CI stayed green. Nik reverted the tab bar in #13548; this PR does not re-land it. It makes ship == CI toolchain and fail-closes the gate class that caused the divergence.The pin
Xcode 26.6, build 17F113 — the newest version+build that exists on both ship surfaces:
macos-26(arm64, image20260907.0351.1):26.6 (default) | 17F113 | /Applications/Xcode_26.6.app— runner-images macos-26 software listmac_mini_m4(10-core/16 GB), image "Xcode 26.6.x (default)":26.6 (17F113) /Applications/Xcode-26.6.app— docs.codemagic.io/specs-macos/xcode-26-6Both vendors carry the exact same build, which also matches the local QA toolchain. Never
latest/edge.What changed
desktop/macos/ci/xcode-pin.json— the single source of truth for version + build + expected app path (with vendor evidence recorded inline).run-swift-ci.shreads the pin file (fails closed if missing) and still asserts the exact version+build after selection.desktop-swift-ci.yml: macOS jobsmacos-15→macos-26; cache key prefixesxcode164→xcode266(16.4 caches cannot poison 26.x builds); select steps name the pinned version. Ubuntu aggregate jobs untouched.codemagic.yaml: onlyomi-desktop-swift-releaseandomi-desktop-swift-previewmove toxcode: 26.6. Android16.4and iOS26.0.1are deliberately untouched. Reviewedcodemagic_workflow_contractdigests refreshed for this edit (same pattern as Refresh the Codemagic fixture digests broken by the Flutter 3.44.5 bump (unblocks Hygiene on every PR) #11673).test_desktop_swift_ci_contract.pyloads the pin file instead of literals, and adds: codemagic pin-agreement (string compare on the two desktop workflows),macos-26runner assertions, and no-stale-xcode164assertions.desktop-compiler-gatesmanifest check (desktop/macos/scripts/check-desktop-compiler-gates.py): fails on#if compiler(...)/#elseif compiler(...)inDesktop/Sources/Desktop/Tests— the exact shape that hid Liquid Glass from the ship toolchain. Runtimeif #available(macOS 26, *)with a working fallback passes. The allowlist is empty and asserted by exact contents, so it cannot silently grow. Registered in.github/checks-manifest.yaml(local+cilanes) with adversarial fixture coverage (.github/scripts/test_check_desktop_compiler_gates.py).CI/infra only — no user-visible change;
no-changelog-needed(no Sparkle/changelog fragment for a toolchain pin, per desktop changelog rules).Test plan
bash desktop/macos/tests/test-run-swift-ci.sh— pin-driven sandbox; wrong-version, wrong-build, and missing-pin sabotage all fail closed (pin 26.6/17F113).python3 .github/scripts/test_desktop_swift_ci_contract.py— 38 tests OK (workflow + runner + codemagic agree with the pin file).python3 .github/scripts/test_check_desktop_compiler_gates.py— 9 tests OK; planted#if compiler(>=6.2)+glassEffectfixture fails the checker, removing it passes; allowlist exact-contents assertion holds.python3 desktop/macos/scripts/check-desktop-compiler-gates.py— real tree: none found (sources ship zero compiler gates today).python3 .github/scripts/check-release-process-guards.py— exit 0 after the digest refresh.xcrun swift build -c debug --package-path Desktopon Xcode 26.6 (17F113) — Build complete! (1855.82s); no Sendable/deprecation fixes were required for the new toolchain.make preflightlocal manifest lane — every selected check passes except the pre-existing loaded-host flaketest_pr_preflight.py::SingleFlightTests::test_identical_processes_join_and_execute_once, which fails 3/3 on pristineorigin/mainat the same host load (passes in isolation) and is unrelated to this diff. CI runs it on dedicated runners.gh pr checks: all green —Desktop Swift Static & Test Contractspass 33m29s on macos-26 (run 34691936150; the cold first run needed the raised 90-min ceiling, warm runs fit comfortably), required aggregateDesktop Swift Build & Testspass,PR Metadata Preflightpass.