iOSSim killing iOS simulator & starts up twice for Safari browser

I am seeing this issue with iOS simulator. Basically it starts up a simulator, kills it and again starts it up.
I found in support category that people set fullReset to true but this is not helping me
is that a ‘feature’ or a bug?

appium log (with caps):

[Appium] Welcome to Appium v1.6.0
[Appium] Appium REST http interface listener started on 0.0.0.0:4723
[HTTP] --> POST /wd/hub/session {“requiredCapabilities”:{},“desiredCapabilities”:{“nativeWebTap”:true,“deviceName”:“iPhone Simulator”,“automationName”:“XCUITest”,“browserName”:“safari”,“safariIgnoreFraudWarning”:true,“newCommandTimeout”:“120”,“platformVersion”:“10.0”,“fullReset”:“true”,“platformName”:“iOS”}}
[MJSONWP] Calling AppiumDriver.createSession() with args: [{“nativeWebTap”:true,"devi…
[Appium] Creating new XCUITestDriver session
[Appium] Capabilities:
[Appium] nativeWebTap: true
[Appium] deviceName: ‘iPhone Simulator’
[Appium] automationName: ‘XCUITest’
[Appium] browserName: ‘safari’
[Appium] safariIgnoreFraudWarning: true
[Appium] newCommandTimeout: ‘120’
[Appium] platformVersion: ‘10.0’
[Appium] fullReset: 'true’
[Appium] platformName: ‘iOS’
[debug] [XCUITest] XCUITestDriver version: 2.0.26
[BaseDriver] Capability ‘fullReset’ changed from string to boolean. This may cause unexpected behavior
[BaseDriver] Capability ‘newCommandTimeout’ changed from string (‘120’) to integer (120). This may cause unexpected behavior
[BaseDriver] Session created with session id: 59c870dd-e2f8-4522-a018-819ee0fdbd75
[debug] [XCUITest] Xcode version set to ‘8.0’
[debug] [XCUITest] iOS SDK Version set to ‘10.0’
[debug] [XCUITest] Changing deviceName from ‘iPhone Simulator’ to ‘iPhone 6’
[iOSSim] Constructing iOS simulator for Xcode version 8.0 with udid ‘CA7C6D33-DCC0-481F-816E-B074DCA720D0’
[debug] [XCUITest] Full reset requested. Cleaning and stopping simulator
[debug] [iOSSim] Killing any simulator daemons for CA7C6D33-DCC0-481F-816E-B074DCA720D0
[iOSSim] Cleaning simulator CA7C6D33-DCC0-481F-816E-B074DCA720D0
[debug] [iOSSim] Killing all iOS Simulators
[XCUITest] Determining device to run tests on: udid: ‘CA7C6D33-DCC0-481F-816E-B074DCA720D0’, real device: false
[XCUITest] Safari test requested
[debug] [iOSLog] Starting iOS 10.0 simulator log capture
[debug] [iOSLog] System log path: /Users/rafalfusik/Library/Logs/CoreSimulator/CA7C6D33-DCC0-481F-816E-B074DCA720D0/system.log
[XCUITest] Setting up simulator
[debug] [iOS] No reason to set locale
[debug] [iOS] Setting iOS and app preferences
[debug] [iOS] No simulator directories found.
[debug] [iOSSim] Attempting to launch and quit the simulator, to create directory structure
[debug] [iOSSim] Will launch with Safari? true
[iOSSim] Starting simulator with command: open /Applications/Xcode.app/Contents/Developer/Applications/Simulator.app --args -CurrentDeviceUDID CA7C6D33-DCC0-481F-816E-B074DCA720D0
[iOSSim] Tailing simulator logs until we encounter the string “SMS Plugin initialized”
[iOSSim] We will time out after 60000ms
[debug] [iOSSim] Waiting an extra 10000ms for the simulator to really finish booting
[debug] [iOSSim] Done waiting extra time for simulator
[iOSSim] Simulator booted in 35987ms
[iOSSim] Tailing simulator logs until we encounter the string “MobileSafari[”
[iOSSim] We will time out after 15000ms
[debug] [iOSSim] Safari started, waiting 3000ms for it to fully start
[debug] [iOSSim] Done waiting for Safari
[debug] [iOSSim] Killing all iOS Simulators
[debug] [iOS] Setting fraudulent website warning to 'false’
[debug] [iOSSim] Updating Safari user settings
[debug] [iOSSim] Building bundle path map
[debug] [iOS] Updated plist files, rebooting the simulator if it’s already open
[debug] [iOS] Killing the simulator
[debug] [iOSSim] Killing all iOS Simulators
[XCUITest] Simulator with udid ‘CA7C6D33-DCC0-481F-816E-B074DCA720D0’ not booted. Booting up now
[debug] [iOSSim] Killing all iOS Simulators
[iOSSim] Starting simulator with command: open /Applications/Xcode.app/Contents/Developer/Applications/Simulator.app --args -CurrentDeviceUDID CA7C6D33-DCC0-481F-816E-B074DCA720D0
[iOSSim] Tailing simulator logs until we encounter the string “SMS Plugin initialized”
[iOSSim] We will time out after 60000ms
[debug] [iOSSim] Waiting an extra 10000ms for the simulator to really finish booting
[debug] [iOSSim] Done waiting extra time for simulator
[iOSSim] Simulator booted in 19188ms
[XCUITest] Using default agent: /usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj
[XCUITest] Using default bootstrap: /usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent
[XCUITest] Launching WebDriverAgent on the device

Can you try using a boolean instead of a string for this capability?

i did try it but to no avail

desired_caps = {
            'browserName': 'safari',
            'platformName': 'iOS',
            'platformVersion': '10.0',
            'deviceName': 'iPhone Simulator',
            'nativeWebTap': True,
            'automationName':'XCUITest',
            'newCommandTimeout':'120', # timeout for a new command
            'fullReset':True,          # to avoid launch twice
            'safariIgnoreFraudWarning': True
        }

That looks so weird to me. You are using Java, correct? I didn’t think boolean values were capitalized. I did a quick web search and I don’t think they are. Here’s one example:

http://codingbat.com/doc/java-if-boolean-logic.html

Also, when you switch the value, does the error change in any way?

it’s Python… the following line from logs imo says they are defined ok

HTTP] --> POST /wd/hub/session {"requiredCapabilities":{},"desiredCapabilities":{"nativeWebTap":true,"deviceName":"iPhone Simulator","automationName":"XCUITest","browserName":"safari","safariIgnoreFraudWarning":true,"newCommandTimeout":"120","platformVersion":"10.0","fullReset":"true","platformName":"iOS"}}