Repository navigation
Skip the iOS simulator terminate right after boot and bound the others - #65
Draft
bitsandfoxes wants to merge 1 commit into
Draft
bitsandfoxes wants to merge 1 commit into
bitsandfoxes wants to merge 1 commit into
Conversation
bitsandfoxes
force-pushed
the
fix/ios-terminate-stall
branch
from
October 25, 2026 22:48
127a3f4 to
992e399
Compare
This was referenced Oct 26, 2026
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.
The iOS simulator provider no longer runs
simctl terminatebefore the first launch after it boots the simulator, and every other terminate is bounded to 60 s. The first launch no longer stalls for minutes.In 150 sentry-unity Run iOS logs, the
simctl terminatebefore the first launch stalled for 59–430 s in 24 legs (16%), for example 349 s here. Later terminates never took more than 14 s, even when the app wasn't running. A first attempt waited forsimctl bootstatusbefore that terminate. In this run,bootstatusreturned within 1 s on all four legs, yet the first terminate still hung in one of them until the 60 s cap. So the stall isn't a boot that hasn't finished, and waiting for one doesn't help.How it works now:
BootSimulator()actually booted the device, the provider skips the terminate. On a freshly booted simulator, the app can't be running. The flag resets on every boot, restart and disconnect. A simulator that was already booted when the provider connected still gets the terminate.simctl terminateis bounded to 60 s, including the one after a run timeout. If the terminate before a launch times out, the launch adds--terminate-running-process, so every launch still starts a fresh process.Tests/iOSSimulatorRunApplication.Tests.ps1runs on macOS only. It uses a fakexcrunand runs the real start, restart and disconnect paths. It covers the skip after a boot, the re-arm after a restart, an already-booted simulator, a hung terminate and its fallback, and killing a hung command.Stacked on #64.
CI evidence: in sentry-unity run 40241909708 (getsentry/sentry-unity#2910, pinned to this commit), every Run iOS leg's first launch started 0 s after "Run log" and later launches within 1–5 s. No terminate timed out, and all 4 legs passed 57/57.
🤖 Generated with Claude Code