App is not installing on the real iOS device

Launching Appium with command: ‘/Applications/Appium.app/Contents/Resources/node/bin/node’ lib/server/main.js --command-timeout “17200” --platform-version “8.3(12F69)” --platform-name “iOS” --app “com.theweathernetwork.weathereyeipad” --udid “730c4d78d0dd08256f51744b44c2a3ceb50f6c67” --show-ios-log --device-name “iPad3_1431” --orientation “Portrait”

info: Welcome to Appium v1.3.7 (REV 72fbfaa116d3d9f6a862600ee99cf02f6d0e2182)

info: Appium REST http interface listener started on 0.0.0.0:4723
info: [debug] Non-default server args: {“app”:“com.theweathernetwork.weathereyeipad”,“udid”:“730c4d78d0dd08256f51744b44c2a3ceb50f6c67”,“deviceName”:“iPad3_1431”,“platformName”:“iOS”,“platformVersion”:“8.3(12F69)”,“orientation”:“Portrait”,“showIOSLog”:true,“defaultCommandTimeout”:17200}
info: Console LogLevel: debug

info: --> GET /wd/hub/status {}

info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}

info: <-- GET /wd/hub/status 200 7.619 ms - 104 {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}

info: --> GET /wd/hub/status {}

info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}

info: <-- GET /wd/hub/status 200 3.395 ms - 104 {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}

info: --> GET /wd/hub/status {}

info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}
info: <-- GET /wd/hub/status 200 0.770 ms - 104 {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}
info: --> GET /wd/hub/sessions {}
info: [debug] Responding to client with success: {“status”:0,“value”:[]}
info: <-- GET /wd/hub/sessions 200 0.785 ms - 23 {“status”:0,“value”:[]}

info: --> POST /wd/hub/session {“desiredCapabilities”:{“platformName”:“iOS”,“platformVersion”:“8.3(12F69)”,“newCommandTimeout”:“999999”,“automationName”:“Appium”,“deviceName”:“iPad3_1431”}}

info: Client User-Agent string: Appium (unknown version) CFNetwork/720.3.13 Darwin/14.3.0 (x86_64)
info: [debug] App is an iOS bundle, will attempt to run as pre-existing
info: [debug] Creating new appium session 7a69ad27-a709-4eb8-ac6c-aa8d564b8e44

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 8.3

info: [debug] Not checking whether simulator is available since we’re on a real device
info: [debug] Detecting automation tracetemplate

info: [debug] Not auto-detecting udid, running on sim
info: [debug] Could not parse plist file (as binary) at /Applications/Appium.app/Contents/Resources/node_modules/appium/com.theweathernetwork.weathereyeipad/en.lproj/Localizable.strings
info: Will try to parse the plist file as XML
info: [debug] Could not parse plist file (as XML) at /Applications/Appium.app/Contents/Resources/node_modules/appium/com.theweathernetwork.weathereyeipad/en.lproj/Localizable.strings
warn: Could not parse app Localizable.strings assuming it doesn’t exist
info: [debug] Creating instruments
info: On some xcode 6 platforms, instruments-without-delay does not work. If you experience this, you will need to re-run appium with the --native-instruments-lib flag
info: [debug] Preparing uiauto bootstrap
info: [debug] Dynamic bootstrap dir: /Users/smanoharan/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,“autoDismissAlerts”:false,“sendKeyStrategy”:“grouped”}
info: [debug] Dynamic bootstrap code: // This file is automatically generated. Do not manually modify!

info: [debug] Dynamic bootstrap path: /Users/smanoharan/Library/Application Support/appium/bootstrap/bootstrap-d5a0fb924946d8d3.js

info: [debug] Reusing dynamic bootstrap: /Users/smanoharan/Library/Application Support/appium/bootstrap/bootstrap-d5a0fb924946d8d3.js
info: [debug] Getting device string from opts: {“forceIphone”:false,“forceIpad”:false,“xcodeVersion”:“6.3”,“iOSSDKVersion”:“8.3”,“deviceName”:“iPad3_1431”,“platformVersion”:“8.3(12F69)”}
info: [debug] fixDevice is on
info: [debug] Final device string is: ‘iPad3_1431 (8.3(12F69) Simulator)’
info: [debug] Not setting device type since we’re on a real device
info: [debug] Checking whether we need to set app preferences
info: [debug] Not setting iOS and app preferences since we’re on a real device
info: [debug] Running ios sim reset flow
info: [debug] Killing the simulator process
info: [debug] Killall iOS Simulator
info: [debug] Killing any other simulator daemons

info: [debug] On a real device; cannot clean device state

info: [debug] Not setting locale because we’re using a real device
info: [debug] No iOS / app preferences to set
info: [debug] Starting iOS device log capture via deviceconsole

info: [debug] Not pre-launching simulator

info: [debug] Creating iDevice object with udid 730c4d78d0dd08256f51744b44c2a3ceb50f6c67
info: [debug] Checking app install status using: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap isInstalled --id 730c4d78d0dd08256f51744b44c2a3ceb50f6c67 --bundle com.theweathernetwork.weathereyeipad

info: [debug] App is not installed. Will try to install the app.

info: [debug] Installing app using cmd: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap install --id 730c4d78d0dd08256f51744b44c2a3ceb50f6c67 --bundle “com.theweathernetwork.weathereyeipad”

info: [debug] Cleaning up appium session

info: [debug] Error: Unable to install [com.theweathernetwork.weathereyeipad] to device with id [730c4d78d0dd08256f51744b44c2a3ceb50f6c67]. Error [Error: Command failed: /bin/sh -c /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap install --id 730c4d78d0dd08256f51744b44c2a3ceb50f6c67 --bundle “com.theweathernetwork.weathereyeipad”
Assertion failed: (access(app_path, F_OK) == 0), function main, file fruitstrap.c, line 718.
]
at /Applications/Appium.app/Contents/Resources/node_modules/appium/lib/devices/common.js:147:10
at ChildProcess.exithandler (child_process.js:751:5)
at ChildProcess.emit (events.js:110:17)
at maybeClose (child_process.js:1008:16)
at Socket. (child_process.js:1176:11)
at Socket.emit (events.js:107:17)
at Pipe.close (net.js:476:12)

error: Failed to start an Appium session, err was: Error: Unable to install [com.theweathernetwork.weathereyeipad] to device with id [730c4d78d0dd08256f51744b44c2a3ceb50f6c67]. Error [Error: Command failed: /bin/sh -c /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap install --id 730c4d78d0dd08256f51744b44c2a3ceb50f6c67 --bundle “com.theweathernetwork.weathereyeipad”
Assertion failed: (access(app_path, F_OK) == 0), function main, file fruitstrap.c, line 718.
]

info: [debug] Responding to client with error: {“status”:33,“value”:{“message”:“A new session could not be created. (Original error: Unable to install [com.theweathernetwork.weathereyeipad] to device with id [730c4d78d0dd08256f51744b44c2a3ceb50f6c67]. Error [Error: Command failed: /bin/sh -c /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap install --id 730c4d78d0dd08256f51744b44c2a3ceb50f6c67 --bundle “com.theweathernetwork.weathereyeipad”\nAssertion failed: (access(app_path, F_OK) == 0), function main, file fruitstrap.c, line 718.\n])”,“origValue”:“Unable to install [com.theweathernetwork.weathereyeipad] to device with id [730c4d78d0dd08256f51744b44c2a3ceb50f6c67]. Error [Error: Command failed: /bin/sh -c /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap install --id 730c4d78d0dd08256f51744b44c2a3ceb50f6c67 --bundle “com.theweathernetwork.weathereyeipad”\nAssertion failed: (access(app_path, F_OK) == 0), function main, file fruitstrap.c, line 718.\n]”},“sessionId”:null}
info: <-- POST /wd/hub/session 500 2417.468 ms - 1026

info: [IOS_SYSLOG_ROW ] Apr 15 15:04:07 iPad3-1431 syslog_relay[821] : syslog_relay found the ASL prompt. Starting…

info: --> GET /wd/hub/status {}

info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}
info: <-- GET /wd/hub/status 200 0.926 ms - 104 {“status”:0,“value”:{“build”:{“version”:“1.3.7”,“revision”:“72fbfaa116d3d9f6a862600ee99cf02f6d0e2182”}}}

info: [IOS_SYSLOG_ROW ] Apr 15 15:04:12 iPad3-1431 kernel[0] : 034873.422620 wlan0.A[35872] AppleBCMWLANNetManager::updateLinkQualityMetrics(): Report LQM to User Land 100, fAverageRSSI -63

Have you built the App to this device through Xcode prior to trying to use Appium and Fruitstrap? How did you install Appium to start? Did you use Homebrew? Have you updated Homebrew lately?

That’s the First “Error” that came up so just making sure you’re able to build to the Device with Fruitstrap properly.

Hi Dan,

Yes I have build the app to this device through xcode before. Build was succeeded and the app launches.
I have installed Appium GUI, Yes I have installed homebrew(recently) and ideviceinstaller from terminal.

I successfully installed the app onto a real device via Xcode. Then I was able to run my automated tests on it.

However, if I try to install the app via Appium GUI (launch inspector), then I get the following error:

2015-07-24 15:30:17:886 - error: Failed to start an Appium session, err was: Error: Installing “BundleID” failed

I checked to make sure the Bundle ID in Xcode matches to the Bundle ID in Appium GUI iOS settings.

I also found this on appium doc saying that Appium will try to install the app onto the real device via Fruitstrap but it also saids it is recommended to pre install the app onto the device via Xcode.

https://github.com/appium/appium/blob/master/docs/en/appium-setup/real-devices.md

Did you guys have to preinstall the app via Xcode in order to run your automated tests? Or you don’t have to? Some help is greatly appreciated! :smile:

My Setup:

  • Appium GUI 1.4.8
  • iPhone 6 iOS 8.1
  • Xcode 6.4

Fixed the problem.

The reason is because I needed to set the provisioning profiles in Xcode.

:slight_smile: