SafariLauncher is not launching Safari

I am trying to test a physical device. I have SafariLauncher installed on the device, the app is trusted and I am able to open the SafariLauncher app. My problem is that Safari never opens. I have opened the SafariLauncher app manually and let the phone sit there for over 5 minutes and Safari never opens. If I click the Launch Safari link manually Safari does open successfully.

I am testing on an iPhone 5s iOS 9.3.2. The default value for the preference_startDelay is set to 20.

I am running the ios_webkit_debug_proxy
I have “Enable UI Automation” enabled.
I have “Web Inspector” enabled under safari settings.

It does seem like as soon as the SafariLauncher app is launched that appium then begins executing my test instead of waiting for Safari to launch.

I am not sure if this is related, but another issue I was having was when I set the “browserName” capability to “Safari” while attempting to test on the physical device I get the following error: “We exceeded the number of retried allowed for instruments to successfully start; failing launch”.

So, I downloaded the SafariLauncher project again and re-built the app. The SafariLauncher app is now launching Safari successfully after 2 seconds.

The issue I am having now is, I have constructed an IOSDriver but I am not able to navigate to a URL. The driver does not seem to be ‘driving’ Safari at all.

I am still seeing an issue with instruments starting when I set the “browserName” to “Safari” capability. The only way I can get the SafariLauncher app to start is by not specifying “Safari” as the “browserName” capability.