Simulator can't be found


#1

As of this week’s xcode update, when we try to forge and run in the simulator, we get an error:

Could not locate simulator for: com.apple.CoreSimulator.SimDeviceType.iPhone-6 iOS 10.3.1 - Please check your Xcode and iOS simulator setup

How do we update local_config.json to work with the updated Xcode?

Obviously, I’ve verified that we have the appropriate version of the SDK installed, and the simulator runs for the device types, I just can’t get Trigger to find it.


#2

Two things to check:

1. I’ve found that Xcode updates will often remove the simulators for the previous version of the iOS SDK.

Can you try editing your local_config.json:

"devicesdk": "iOS 11.0"

2. Are you still on platform version v2.5.x? Apple shipped some breakage with Xcode 9.0 that can cause issues with some simulator configurations. Upgrading to Forge v2.6.2 will ensure full compatibility with Xcode 9.0.


Otherwise, over the years we’ve also found that Xcode doesn’t always do a good job of initializing the new simulator definitions after an upgrade.

On some of my machines I’ve often found I need to run Xcode a few times, do a reboot (or two!) and maybe even launch a native app on the Simulator from Xcode itself before the definitions become accessible to anything outside of it.

You can also try a hard reset of the Xcode links:

sudo xcode-select --reset

Another thing to check for sanity is to run the command Forge uses to enumerate the available simulators and make sure the combination you requested is available:

xcrun simctl list

#3

Edited for thread clarity, because issue was tangential to original post :slight_smile:


#4

With our latest update to xcode 10.2.1, this issue has returned. We’re on the latest Trigger platform, have tried varying the devicesdk, confirming the simulator we’re invoking is available via xcrun simctl list, hard reset the Xcode links via sudo xcode-select --reset, started the simulator, launched the native apps that come with the simulator on the simulator, restarted xcode several times, restarted the simulator several times, rebooted the computer several times, no luck.

Any additional advice?


#5

With the latest Xcode point release Apple arbitrarily changed their simulator configs to be keyed by runtime identifier rather than runtime name.

Can you please try our staging build: v2.7.8

https://trigger.io/docs/current/api/release_notes.html


#6

That solved it, thank you!