Skip to content

Commit a206fd2

Browse files
committed
[3.14] gh-153631: Move to macos-26 runner for iOS (GH-153632)
Switches iOS CI to use the macos-26 runner, and makes a small change to the iOS build script to improve build stability. xcodebuild doesn't guarantee that the CoreSimulatorService is running before starting a simulator. If the service isn't running, xcodebuild reports that no simulators are available, and fails to start the test app. However, simctl blocks until the simulator is available, and simctl is used to evaluate the default simulator. So - the iOS build script now unconditionally determines the default simulator, even if a specific simulator is requested. (cherry picked from commit 2dc1a91) Co-authored-by: Russell Keith-Magee <russell@keith-magee.com>
1 parent c628cd7 commit a206fd2

2 files changed

Lines changed: 9 additions & 12 deletions

File tree

.github/workflows/build.yml

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -387,23 +387,14 @@ jobs:
387387
needs: build-context
388388
if: needs.build-context.outputs.run-ios == 'true'
389389
timeout-minutes: 60
390-
runs-on: macos-14
390+
runs-on: macos-26
391391
steps:
392392
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
393393
with:
394394
persist-credentials: false
395395

396-
# GitHub recommends explicitly selecting the desired Xcode version:
397-
# https://github.com/actions/runner-images/issues/12541#issuecomment-3083850140
398-
# This became a necessity as a result of
399-
# https://github.com/actions/runner-images/issues/12541 and
400-
# https://github.com/actions/runner-images/issues/12751.
401-
- name: Select Xcode version
402-
run: |
403-
sudo xcode-select --switch /Applications/Xcode_15.4.app
404-
405396
- name: Build and test
406-
run: python3 Apple ci iOS --fast-ci --simulator 'iPhone SE (3rd generation),OS=17.5'
397+
run: python3 Apple ci iOS --fast-ci
407398

408399
build-emscripten:
409400
name: 'Emscripten'

Apple/testbed/__main__.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,8 +271,14 @@ def run_testbed(
271271
update_test_plan(location, platform, args)
272272
print(" done.")
273273

274+
# xcodebuild doesn't guarantee that the CoreSimulatorService daemon is
275+
# running prior to using a simulator, but calling `xcrun simctl list` does.
276+
# Determining the default simulator that *would* be used is a cheap action;
277+
# so use that as a way to ensure that the CoreSimulatorService daemon is
278+
# running.
279+
default_simulator = select_simulator_device(platform)
274280
if simulator is None:
275-
simulator = select_simulator_device(platform)
281+
simulator = default_simulator
276282
print(f"Running test on {simulator}")
277283

278284
xcode_test(

0 commit comments

Comments
 (0)