Failed to start an Appium session, err was: Error: Command failed: /bin/sh -c ideviceinstaller
See original GitHub issueThe problem
Could not start a new session Be sure the Appium server is running with an application opened by using the “App Path” parameter in Appium.app (along with package and activity for Android) or by connecting with selenium client and supplying this in the desired capabilities object.
info: [debug] Error: Command failed: /bin/sh -c ideviceinstaller -u 02DEECB0-7D84-4817-830E-F43D2E51881F -i /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app
Environment
- MacOS: 10.11.13
- xCode 7.2.1
- Appium 1.4.13
- Simulator (iPhone 5 (8.4); UDID: 02DEECB0-7D84-4817-830E-F43D2E51881F)
- Setup for Appium: 2.1 iOS Setting
- App: /Users/qaname/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app
- Force Device: iPhone 5
- Platform version: 8.4
- Full reset
2.2 General Settings
- Server Address: 127.0.0.1
- Port: 4723
- Check for update
- New command timeout : 7200s
- Appium version (or git revision) that exhibits the issue:
- Last Appium version that did not exhibit the issue (if applicable):
- Desktop OS/version used to run Appium:
- Node.js version (unless using Appium.app|exe):
- Mobile platform/version under test:
- Real device or emulator/simulator:
- Appium CLI or Appium.app|exe:
Details
Press the Launch button then Launching Appium with command: ‘/Applications/Appium.app/Contents/Resources/node/bin/node’ lib/server/main.js --address “127.0.0.1” --command-timeout “7200” --log-no-colors --debug-log-spacing --platform-version “8.4” --platform-name “iOS” --app “/Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app” --udid “02DEECB0-7D84-4817-830E-F43D2E51881F” --full-reset --device-name “iPhone 5”
info: Welcome to Appium v1.4.13 (REV c75d8adcb66a75818a542fe1891a34260c21f76a)
info: Appium REST http interface listener started on 127.0.0.1:4723
info: [debug] Non-default server args: {“app”:“/Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app”,“udid”:“02DEECB0-7D84-4817-830E-F43D2E51881F”,“address”:“127.0.0.1”,“fullReset”:true,“logNoColors”:true,“deviceName”:“iPhone 5”,“platformName”:“iOS”,“platformVersion”:“8.4”,“defaultCommandTimeout”:7200,“debugLogSpacing”:true} info: Console LogLevel: debug
info: --> GET /wd/hub/status {}
info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
info: <-- GET /wd/hub/status 200 16.336 ms - 105 {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
- Next, press the Inspector button then
- Bug: Could not start a new session Be sure the Appium server is running with an application opened by using the “App Path” parameter in Appium.app (along with package and activity for Android) or by connecting with selenium client and supplying this in the desired capabilities object.
- Terminal: Launching Appium with command: ‘/Applications/Appium.app/Contents/Resources/node/bin/node’ lib/server/main.js --address “127.0.0.1” --command-timeout “7200” --log-no-colors --debug-log-spacing --platform-version “8.4” --platform-name “iOS” --app “/Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app” --udid “02DEECB0-7D84-4817-830E-F43D2E51881F” --full-reset --device-name “iPhone 5”
info: Welcome to Appium v1.4.13 (REV c75d8adcb66a75818a542fe1891a34260c21f76a)
info: Appium REST http interface listener started on 127.0.0.1:4723
info: [debug] Non-default server args: {“app”:“/Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app”,“udid”:“02DEECB0-7D84-4817-830E-F43D2E51881F”,“address”:“127.0.0.1”,“fullReset”:true,“logNoColors”:true,“deviceName”:“iPhone 5”,“platformName”:“iOS”,“platformVersion”:“8.4”,“defaultCommandTimeout”:7200,“debugLogSpacing”:true} info: Console LogLevel: debug
info: --> GET /wd/hub/status {}
info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
info: <-- GET /wd/hub/status 200 16.336 ms - 105 {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
info: --> GET /wd/hub/status {}
info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
info: <-- GET /wd/hub/status 200 6.693 ms - 105 {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
info: --> GET /wd/hub/status {}
info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
info: <-- GET /wd/hub/status 200 3.090 ms - 105 {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}} info: --> GET /wd/hub/sessions {} info: [debug] Responding to client with success: {“status”:0,“value”:[]}
info: <-- GET /wd/hub/sessions 200 8.509 ms - 23 {“status”:0,“value”:[]}
info: --> POST /wd/hub/session {“desiredCapabilities”:{“platformName”:“iOS”,“platformVersion”:“8.4”,“newCommandTimeout”:“999999”,“automationName”:“Appium”,“deviceName”:“iPhone 5”}}
info: Client User-Agent string: Appium (unknown version) CFNetwork/760.2.6 Darwin/15.3.0 (x86_64) info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: **** NEW SESSION *** info: **** NEW SESSION *** info: **** NEW SESSION *** info: **** NEW SESSION *** info: **** NEW SESSION *** info: **** NEW SESSION *** info: **** NEW SESSION *** info: **** NEW SESSION *** info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: ************************************* info: *************************************
info: [debug] Using local app from command line: /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app info: [debug] Creating new appium session 7fb6f4c5-1964-47e8-9dbc-39650b607807 info: [debug] Removing any remaining instruments sockets info: [debug] Cleaned up instruments socket /tmp/instruments_sock info: [debug] Auto-detecting iOS udid… info: [debug] Not auto-detecting udid, running on sim info: [debug] Could not parse plist file (as binary) at /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app/en.lproj/Localizable.strings info: Will try to parse the plist file as XML info: [debug] Could not parse plist file (as XML) at /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app/en.lproj/Localizable.strings warn: Could not parse app Localizable.strings assuming it doesn’t exist 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/le.thi.minh.ha/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/submodules/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/le.thi.minh.ha/Library/Application Support/appium/bootstrap/bootstrap-5923cadea0343e3f.js
info: [debug] Reusing dynamic bootstrap: /Users/le.thi.minh.ha/Library/Application Support/appium/bootstrap/bootstrap-5923cadea0343e3f.js info: [debug] Attempting iOS device log capture via libimobiledevice idevicesyslog
info: [debug] Creating iDevice object with udid 02DEECB0-7D84-4817-830E-F43D2E51881F
info: [debug] App is not installed. Will try to install the app.
info: [debug] Cleaning up appium session
info: [debug] Error: Command failed: /bin/sh -c ideviceinstaller -u 02DEECB0-7D84-4817-830E-F43D2E51881F -i /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app
at ChildProcess.exithandler (child_process.js:751:12)
at ChildProcess.emit (events.js:110:17)
at maybeClose (child_process.js:1015:16)
at Socket.<anonymous> (child_process.js:1183:11)
at Socket.emit (events.js:107:17)
at Pipe.close (net.js:485:12)
info: [debug] Responding to client with error: {“status”:33,“value”:{“message”:“A new session could not be created. (Original error: Command failed: /bin/sh -c ideviceinstaller -u 02DEECB0-7D84-4817-830E-F43D2E51881F -i /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app\n)”,“killed”:false,“code”:2,“signal”:null,“cmd”:“/bin/sh -c ideviceinstaller -u 02DEECB0-7D84-4817-830E-F43D2E51881F -i /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app”,“origValue”:“Command failed: /bin/sh -c ideviceinstaller -u 02DEECB0-7D84-4817-830E-F43D2E51881F -i /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app\n”},“sessionId”:null}
error: Failed to start an Appium session, err was: Error: Command failed: /bin/sh -c ideviceinstaller -u 02DEECB0-7D84-4817-830E-F43D2E51881F -i /Users/le.thi.minh.ha/Library/Developer/Xcode/DerivedData/Recipes-drkyknrlwrisjtdmnfsegmcqvyzx/Build/Products/Debug-iphonesimulator/Recipes.app
info: <-- POST /wd/hub/session 500 506.522 ms - 847
info: --> GET /wd/hub/status {}
info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}} info: <-- GET /wd/hub/status 200 1.754 ms - 105 {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
info: --> GET /wd/hub/status {}
info: [debug] Responding to client with success: {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}} info: <-- GET /wd/hub/status 200 2.196 ms - 105 {“status”:0,“value”:{“build”:{“version”:“1.4.13”,“revision”:“c75d8adcb66a75818a542fe1891a34260c21f76a”}}}
Issue Analytics
- State:
- Created 7 years ago
- Comments:10 (3 by maintainers)
Top GitHub Comments
Don’t use
--udid
. This indicated to the server that you are using a real device. For a simulator there should be no involvement withideviceinstaller
, which is only used to install to a real device.This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.