Repository navigation
CI: wait for the iOS simulator before testing - #30
Merged
Merged
Conversation
On a fresh macos-26 runner the simulator service can start late. xcodebuild then lists no simulators at all and the iOS job fails with "Unable to find a device matching the provided destination specifier" after its own 60-second wait (Perfect-SQLite #29, second attempt; a retry passed). This matches actions/runner-images#12948. Before testing, poll xcodebuild -showdestinations for the iPhone 17 for up to 5 minutes. Each round first runs simctl list, the workaround from that issue, which makes the service refresh its runtimes. xcodebuild's errors stay in the log, so a package-resolution failure isn't hidden. The test also gets -destination-timeout 120 in case the device drops out again between the check and the run. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Summary
Fixes an occasional iOS CI failure: "Unable to find a device matching the provided destination specifier". On a fresh macos-26 runner the simulator service sometimes starts late. xcodebuild then waits 60 seconds, lists no simulators at all (only placeholders), and fails. This happened on #29's second attempt, and a retry passed. It matches actions/runner-images#12948.
xcodebuild -showdestinationsfor the iPhone 17 for up to 5 minutes. Each round first runsxcrun simctl list, which is the workaround from that issue: it makes the service refresh its runtimes. xcodebuild's errors stay in the log, so a package-resolution failure isn't hidden behind a "no simulator" message.xcodebuild testalso gets-destination-timeout 120, in case the device drops out between the check and the run.Testing
Locally, I ran the step under the runner's shell (
bash -e). The success path exits as soon as the iPhone 17 is listed. The timeout path reports and exits 1. CRUD's iOS tests pass 179/179 with the new flag. The real test is this PR's CI on GitHub. Per the issue thread, this makes the flake rarer but doesn't guarantee it's gone.🤖 Generated with Claude Code