Below is the Appium logs:
Launching Appium with command: ‘/Applications/Appium.app/Contents/Resources/node/bin/node’ lib/server/main.js --address “127.0.0.1” --command-timeout “7200” --pre-launch --log-no-colors --platform-version “7.1” --platform-name “iOS” --app “/Users/QA/Desktop/***/***.app” --device-name “iPad Retina” --isolate-sim-device
info: [debug] Starting Appium in pre-launch mode
info: Pre-launching app
info: [debug] Using local app from command line: /Users/QA/Desktop/***/***.app
info: [debug] Creating new appium session b40fe965-1e6e-49b4-9a9c-05eeb5350cb6
info: [debug] Removing any remaining instruments sockets
info: [debug] Cleaned up instruments socket /tmp/instruments_sock
info: [debug] Setting Xcode folder
info: [debug] Setting Xcode version
info: [debug] Setting iOS SDK Version
info: [debug] Getting sdk version from xcrun with a timeout
info: [debug] iOS SDK Version set to 7.1
info: [debug] Checking whether instruments supports our device string
info: [debug] Getting list of devices instruments supports
info: [debug] Instruments is at: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments
info: [debug] Getting device string from opts: {“forceIphone”:false,“forceIpad”:false,“xcodeVersion”:“5.1.1”,“iOSSDKVersion”:“7.1”,“deviceName”:“iPad Retina”,“platformVersion”:“7.1”}
info: [debug] fixDevice is on
info: [debug] Final device string is: ‘iPad Retina - Simulator - iOS 7.1’
info: [debug] Detecting automation tracetemplate
info: [debug] Not auto-detecting udid, running on sim
info: [debug] Parsed app Info.plist (as binary)
info: [debug] Parsed app Localizable.strings
info: [debug] Getting bundle ID from app
info: [debug] Parsed app Info.plist (as binary)
info: [debug] Creating instruments
info: [debug] Preparing uiauto bootstrap
info: [debug] Dynamic bootstrap dir: /Users/QA/Library/Application Support/appium/bootstrap
info: [debug] Dynamic env: {“nodePath”:"/Applications/Appium.app/Contents/Resources/node/bin/node",“commandProxyClientPath”:"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-uiauto/bin/command-proxy-client.js",“instrumentsSock”:"/tmp/instruments_sock",“interKeyDelay”:null,“justLoopInfinitely”:false,“autoAcceptAlerts”:false,“sendKeyStrategy”:“oneByOne”}
info: [debug] Dynamic bootstrap code: // This file is automatically generated. Do not manually modify!
…
info: [debug] Dynamic bootstrap path: /Users/QA/Library/Application Support/appium/bootstrap/bootstrap-a4a902c9cce7b6cb.js
info: [debug] Reusing dynamic bootstrap: /Users/QA/Library/Application Support/appium/bootstrap/bootstrap-a4a902c9cce7b6cb.js
info: [debug] Getting device string from opts: {“forceIphone”:false,“forceIpad”:false,“xcodeVersion”:“5.1.1”,“iOSSDKVersion”:“7.1”,“deviceName”:“iPad Retina”,“platformVersion”:“7.1”}
info: [debug] fixDevice is on
info: [debug] Final device string is: ‘iPad Retina - Simulator - iOS 7.1’
info: [debug] We’re on iOS7.1+ so forcing defaultDevice on
info: [debug] Getting device string from opts: {“forceIphone”:false,“forceIpad”:false,“xcodeVersion”:“5.1.1”,“iOSSDKVersion”:“7.1”,“deviceName”:“iPad Retina”,“platformVersion”:“7.1”}
info: [debug] fixDevice is on
info: [debug] Final device string is: ‘iPad Retina - Simulator - iOS 7.1’
info: [debug] Parsed app Info.plist (as binary)
info: [debug] Wrote new app Info.plist with device type
info: [debug] Checking whether we need to set app preferences
info: [debug] Running ios sim reset flow
info: [debug] Killing the simulator process
info: [debug] Killall iPhoneSimulator
info: [debug] Killing any other simulator daemons
info: [debug] Cleaning sim data files
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1/Library/TCC
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1/Library/Caches/locationd
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1/Library/BackBoard/applicationState.plist
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1/Media
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1/Library/Keychains
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1-64/Library/TCC
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1-64/Library/Caches/locationd
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1-64/Library/BackBoard/applicationState.plist
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1-64/Media
info: [debug] Deleting /Users/QA/Library/Application Support/iPhone Simulator/7.1-64/Library/Keychains
info: [debug] Cleaning sim preferences
info: [debug] Clearing key: SimulateDevice
info: [debug] Writing new preferences plist data
info: [debug] Cleaning app data files
warn: Applications directory /Users/QA/Library/Application Support/iPhone Simulator/7.1/Applications doesn’t exist. Have you run this simulator before?
warn: Applications directory /Users/QA/Library/Application Support/iPhone Simulator/7.1-64/Applications doesn’t exist. Have you run this simulator before?
info: Couldn’t find app directories to delete. Probably it’s not installed
info: [debug] Not setting locale
info: [debug] No iOS / app preferences to set
info: [debug] Starting iOS 7.* simulator log capture
info: [debug] Not pre-launching simulator
info: [debug] No device id or app, not installing to real device.
info: [debug] Starting command proxy.
info: [debug] Instruments socket server started at /tmp/instruments_sock
info: [debug] Starting instruments
info: [debug] Instruments is at: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments
info: Launching instruments
info: [debug] Attempting to run app on iPad Retina - Simulator - iOS 7.1
info: [debug] Spawning instruments with command: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments -t /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate -D /tmp/appium-instruments/instrumentscli0.trace -w “iPad Retina - Simulator - iOS 7.1” /Users/QA/Desktop/***/***.app -e UIASCRIPT “/Users/QA/Library/Application Support/appium/bootstrap/bootstrap-a4a902c9cce7b6cb.js” -e UIARESULTSPATH /tmp/appium-instruments
info: [debug] And extra without-delay env: {“DYLD_INSERT_LIBRARIES”:"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-instruments/thirdparty/iwd5/InstrumentsShim.dylib",“LIB_PATH”:"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-instruments/thirdparty/iwd5"}
info: [debug] And launch timeouts (in ms): {“global”:90000}
info: [debug] [INST STDERR] Instruments Trace Error : Error Starting Recording
info: [debug] [INSTSERVER] Instruments exited with code 253
info: [debug] Killall instruments
info: [debug] Instruments crashed on startup
info: [debug] Attempting to retry launching instruments, this is retry #1
info: [debug] Killall iPhoneSimulator
info: Launching instruments
info: [debug] Attempting to run app on iPad Retina - Simulator - iOS 7.1
info: [debug] Spawning instruments with command: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments -t /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate -D /tmp/appium-instruments/instrumentscli0.trace -w “iPad Retina - Simulator - iOS 7.1” /Users/QA/Desktop/***/***.app -e UIASCRIPT “/Users/QA/Library/Application Support/appium/bootstrap/bootstrap-a4a902c9cce7b6cb.js” -e UIARESULTSPATH /tmp/appium-instruments
info: [debug] And extra without-delay env: {“DYLD_INSERT_LIBRARIES”:"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-instruments/thirdparty/iwd5/InstrumentsShim.dylib",“LIB_PATH”:"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-instruments/thirdparty/iwd5"}
info: [debug] And launch timeouts (in ms): {“global”:90000}
xcode ver:5.1.1
Appium v1.2.3
node- v0.10.32.pkg
selenium-java-2.43.1
java-client-1.0.1
Eclipse:4.4.0
Explaining the scenario:
- When launching my app via appium GUI , that log is generated and ipad simulator is launched but not my application then simulator will close. same thing will happen trice and a “simulator timeout message” will be shown before appium stops.
- When launching via eclipse java code , there i am starting the appium server by OSx terminal : “Appium &” and running the code using testng. But here problem is simulator will launch the app and close down simulator, these opening and closing of simulator/app will happens for 4 times then finally test case fails.
Question:
Can any one help me to solve the issue?
Note: after taking appium update all these problem i am facing, but if i am Testing the app using script in real device (ipad) then there is no issues. But i need to use simulator for inspecting elements on the run .