Xcode 8.3.3 introduced iOS SDK 10.3.1 which causes some troubles for ioslib. ioslib ties the simulator to the iOS SDK tied to the simulator runtime in the runtime's plist file, which is "10.3" even for "10.3.1". ioslib cheats and skips this and just associates the sim with the iOS SDK installed with Xcode.
Since Xcode 8.3.3 comes with iOS 10.3.1, ioslib will naively define an iOS 10.3.1 simulator.
When autoselecting a simulator, it scans the Xcode iOS Simulators, namely 10.3.1, and tries to load the simulator details, which are associated to the iOS SDK tied to the sim runtime. In this case, the 8.3 sim runtime is tied to iOS SDK 8.3 as defined in the sim runtime's plist.
When ioslib tries to lookup a 10.3.1 simulator, it won't find any matches and hence the error:
The solution is to create a distinct list of iOS SDKs associated to each sim runtime based on both the sim runtime's plist and the output from simctl. While the plist will return "10.3", simctl will return "10.3.1". We can then loop over each version and define the same simulator for both iOS SDKs. Redundant? Yes. Does it work? Yes.
On a side note, there's a small bug where the correct simulator is being selected, but the wrong Xcode version. It is supposed to pick the most recent Xcode that supports the selected Xcode. However there's a bug where we A) don't filter unsupported Xcodes and B) we don't break the loop after the first recent match resulting in the oldest Xcode being selected.