Product

Don't Run Simulator Tests on getmac-golden-gate-rc Yet

By GetMac Team••
5 min read
Don't Run Simulator Tests on getmac-golden-gate-rc Yet

If your jobs run iOS simulator tests on getmac-golden-gate-rc, our macOS 27 image, move them to getmac-tahoe-rc for now. There is a bug in macOS 27 that can remove a simulator runtime from under a test that is already running, and we have not found a way to prevent it from our side.

This is an advisory rather than a release note. The short version: the image is fine for building, and not fine for simulator tests.

What it looks like

A test run that worked yesterday fails today, on the same commit. The error varies depending on exactly when it lands:

Failed to find service com.apple.CoreSimulator.host_support in session
com.apple.CoreSimulator.SimDevice.<uuid>. (Underlying Error: ... No such process)

The iOS 27.0 simulator runtime is not available. runtime path not found.

Invalid runtime: com.apple.CoreSimulator.SimRuntime.iOS-27-0

The first appears when the runtime goes away mid-session. The second and third appear afterwards, and in the worst case the machine cannot create an iOS 27 simulator again for the rest of its life — every later step in the job fails, no matter what it does.

Re-running usually passes, which is what makes it so unpleasant. It looks like flakiness in your test suite, and it is not.

What is actually happening

A simulator runtime is not a folder. It is a disk image that macOS mounts, and simdiskimaged manages those mounts. On macOS 27 a runtime gets mounted twice during a machine's first minutes: once the old way, under /Library/Developer/CoreSimulator/Volumes, and once as a cryptex, under cryptexd. The second registration is the one macOS prefers; the first is left marked Unusable - Cryptex Mount Preferred.

Those leftovers are not cleaned up immediately. They sit there for about twelve minutes, and then a scan clears them out. If a simulator is running from a mount that scan removes, the simulator dies without warning — and the runtime registration can go with it.

It is on file as a known issue in the Xcode 27.3 beta 2 release notes:

A simulator device might be shut down without warning if its runtime was mounted as a disk image and subsequently remounted as a cryptex. (191574717)

There is no released fix yet, and the mounting behaviour is the operating system's, not something an image can opt out of.

What we measured

We built a test harness that loops a parallel-testing xcodebuild test run — the kind that clones a simulator for each worker — and watches every runtime's mount and registration state every ten seconds. Everything below is from our own CI on our own images.

The duplicate registrations appear and settle quickly, and are cleared much later:

machine uptimestate
0s18 runtimes, no duplicates
50–90sduplicates appear as runtimes are remounted as cryptexes
90–180ssettles, holding 10 stale registrations
12–17 mina scan clears the 10 stale registrations — this is where tests die
afterstable for the rest of the machine's life

One run caught it precisely: the duplicate count fell from 10 to 8 to 6 to 0 between twelve and sixteen minutes of uptime, and the test that failed did so at thirteen minutes, mid-clear, producing zero simulator clones. Every run afterwards passed.

Across nine macOS 27 machines with an iOS 27 runtime pinned:

  • three lost the runtime permanently, at 11.0, 11.2 and 12.1 minutes of uptime
  • the other six each took a recoverable failure inside the same window, then ran clean — one for two hours straight
  • every failure we have seen, in every run, landed in that window. Nothing has ever failed outside it

It is not specific to iOS 27.0. We reproduced it on iOS 27.2 as well. It is not memory, disk, CPU, concurrency or a particular test suite — we measured and excluded each of those.

And it does not happen on macOS 26. The same Xcode, the same iOS 27.0 runtime and the same workload on getmac-tahoe-rc ran 74 minutes and 20 iterations without ever losing the runtime, straight through several of these windows. The macOS 26 host clears the same leftovers gracefully; macOS 27 does not.

What to do

Use getmac-tahoe-rc for simulator tests. It is macOS Tahoe 26.6.2 with Xcode 27.2 as the default and the same iOS 27.0, 27.1 and 27.2 runtimes installed, so in most cases this is a one-line change:

jobs:
  test:
    runs-on: getmac-tahoe-rc   # was: getmac-golden-gate-rc

If you are on getmac-golden-gate-rc deliberately — to build against macOS 27 itself — builds are unaffected. It is simulator tests specifically that are at risk.

Two things that do not help, so you can skip trying them:

  • Reducing concurrency or simulator workers. The scan runs on its own schedule. Fewer parallel tests means fewer tests in flight when it fires, not a smaller chance of it firing.
  • Cleaning up the duplicate runtimes at the start of your job. We tried this. At that point the remounting has not finished, so everything you delete comes straight back, and the scan still has work to do twelve minutes later.

What we are doing

Three things.

Repointing the label. getmac-golden-gate-rc will point at the macOS 26 image, so existing workflows keep working without edits while this is outstanding. We will not disable the label — a job whose first label does not match anything is dropped silently, and nobody should discover this through a queue that never drains.

Testing new images far harder than we were. Nothing in our own image checks would have caught this. They confirmed each runtime was present and bootable, which it was. They never looked at how a runtime was mounted, whether it was registered once or twice, or what state a machine is in fifteen minutes into its life rather than one — and any of those three would have caught it. All of them are going into the image tests, along with a parallel-testing run that actually clones simulators, which is the workload that exposes this and which none of our previous image tests performed.

Waiting on the Xcode developers. The mounting is the operating system's and the bug is theirs to fix. We found nothing an image or a job can do to avoid it that would not cost every build more time than the failure itself does. When a fix ships we will say so here.

If you have been seeing unexplained simulator failures on macOS 27, this is very likely the cause, and it is ours to carry rather than yours to debug. Come and tell us in Discord if you are affected — knowing which runtimes people depend on helps us decide what to ship next.

— The GetMac Team

#product#macos#xcode#simulator#ci-cd#advisory
Don't Run Simulator Tests on getmac-golden-gate-rc Yet | GetMac