Works fine in same setup if only 1 device connected via USB. e.g. still 2 instances of Appium, but 1 device connected, and the driver session specifies which instance/port of Appium to connect to.
With 2 devices, even while specifying specifically which instance/port to connect to, it fails to launch the app under test (for even just one device, not talking about parallel execution yet, only parallel appium instances running at the moment) and driver session throws exception. Details error & logs below. Based on some of the output, seems appium or rather adb canāt handle dealing with multiple connected devices.
I think Iām using latest Android SDK/adb (adb v1.0.32) that I got off colleague and then ran some updates on it to pull for API 23 / Android 6. Iām using latest version of appium for both node.js binary (used here) as well as Appium.app. As for device connection, I just had the Android Moto Eās enabled for USB debugging, and connected via USB to my Mac. Nothing more done.
How do I set up my environment such that Appium and adb can deal with multiple connected devices and know to route to which device? Looking at some appium docs (starting from http://appium.io/slate/en/master/?ruby#server-flags) I canāt tell how you can map an Appium instance to a specific device, or point out to which one as well in the desired capabilities, assuming you have 2x of the same device type. At least on iOS, thereās the UDID parameter.
In my appium instance launch, itās the same startup parameters (see below) other than different ports.
(python) client error:
d = webdriver.Remote( command_executor=āhttp://127.0.0.1:8081/wd/hubā, desired_capabilities={āplatformNameā:āAndroidā,āplatformVersionā:ā5.1ā,ādevice IDā:ā00000000-0000-0000-0000-e4907e2df4baā,ādeviceNameā:āMoto Eā})
Traceback (most recent call last):
File āā, line 1, in
File ā/usr/local/lib/python2.7/site-packages/appium/webdriver/webdriver.pyā, line 36, in init
super(WebDriver, self).init(command_executor, desired_capabilities, browser_profile, proxy, keep_alive)
File ā/usr/local/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.pyā, line 87, in init
self.start_session(desired_capabilities, browser_profile)
File ā/usr/local/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.pyā, line 141, in start_session
ādesiredCapabilitiesā: desired_capabilities,
File ā/usr/local/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.pyā, line 201, in execute
self.error_handler.check_response(response)
File ā/usr/local/lib/python2.7/site-packages/selenium/webdriver/remote/errorhandler.pyā, line 181, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: An unknown server-side error occurred while processing the command. Original error: Cannot read property āstopā of undefined
Appium server logs:
appium --port ā8081ā --command-timeout ā7200ā --debug-log-spacing --automation-name āAppiumā --platform-name āAndroidā --platform-version ā5.1ā --app ā/pathTo/app.apkā
[Appium] Welcome to Appium v1.5.0-beta9 (REV ad64e01ff4e4569f6a1e8c09b480d9c045aaf513)
[Appium] Appium REST http interface listener started on 0.0.0.0:8081
[Appium] Non-default server args:
[Appium] port: 8081
[Appium] defaultCommandTimeout: 7200
[Appium] debugLogSpacing: true
[Appium] platformName: Android
[Appium] platformVersion: 5.1
[Appium] automationName: Appium
[Appium] app: /pathTo/app.apk
[Appium] Deprecated server args:
[Appium] --platform-name => --default-capabilities ā{āplatformNameā:āAndroidā}ā
[Appium] --platform-version => --default-capabilities ā{āplatformVersionā:ā5.1ā}ā
[Appium] --automation-name => --default-capabilities ā{āautomationNameā:āAppiumā}ā
[Appium] --app => --default-capabilities ā{āappā:"/pathTo/app.apk"}ā
[Appium] Default capabilities, which will be added to each request unless overridden by desired capabilities: {āplatformNameā:āAndroidā,āplatformVersionā:ā5.1ā,āautomationNameā:āAppiumā,āappā:"/pathTo/app.apk"}
[HTTP] --> POST /wd/hub/session
[MJSONWP] Calling AppiumDriver.createSession() with args: [{āplatformVersionā:ā5.1ā,ādevice IDā:ā00000000-0000-0000-0000-e4907e2df4baā,āplatformNameā:āAndroidā,ādeviceNameā:āMoto Eā},null,null,null]
[Appium] Creating new AndroidDriver session
[BaseDriver] The following capabilities were provided, but are not recognized by appium: device ID.
[BaseDriver] Session created with session id: 7e2ffd8e-f2c8-498f-9cc5-0a505445910b
[debug] [AndroidDriver] Getting Java version
[AndroidDriver] Java version is: 1.8.0_66
[ADB] Checking whether adb is present
[ADB] Using adb from /Applications/AndroidDev/sdk/platform-tools/adb
[BaseDriver] Using local app ā/pathTo/app.apkā
[debug] [AndroidDriver] Checking whether app is actually present
[AndroidDriver] Starting Android session
[AndroidDriver] Retrieving device list
[debug] [ADB] Trying to find a connected android device
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[AndroidDriver] Found device: TA0930ALF7
[debug] [ADB] Setting device id to TA0930ALF7
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āwait-for-deviceā]
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āechoā,āpingā]
[debug] [Logcat] Starting logcat capture
[debug] [AndroidDriver] Pushing settings apk to deviceā¦
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āinstallā,"/usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/io.appium.settings/bin/settings_apk-debug.apk"]
[debug] [AndroidDriver] Pushing unlock helper app to deviceā¦
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āinstallā,"/usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-unlock/bin/unlock_apk-debug.apk"]
[ADB] Getting device platform version
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āgetpropā,āro.build.version.releaseā]
[debug] [AndroidDriver] Parsing package and activity from app manifest
[ADB] Checking whether aapt is present
[ADB] Using aapt from /Applications/AndroidDev/sdk/build-tools/23.0.2/aapt
[ADB] Extracting package and launch activity from manifest
[debug] [ADB] badging package: com.blah.blah
[debug] [ADB] badging act: com.blah.blah.MainActivity
[debug] [AndroidDriver] Parsed package and activity are: com.blah.blah/com.blah.blah.MainActivity
[debug] [ADB] Uninstalling com.blah.blah
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āamā,āforce-stopā,ācom.blah.blahā]
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āuninstallā,ācom.blah.blahā]
[ADB] App was not uninstalled, maybe it wasnāt on device?
[AndroidDriver] Remote apk path is /data/local/tmp/8e431a8da3b643581864d3ea5f739fe2.apk
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,ālsā,"/data/local/tmp/8e431a8da3b643581864d3ea5f739fe2.apk"]
[debug] [AndroidDriver] Checking if app is installed
[debug] [ADB] Getting install status for com.blah.blah
[ADB] Getting device API level
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āgetpropā,āro.build.version.sdkā]
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āpmā,ālistā,āpackagesā,"-3",ācom.blah.blahā]
[debug] [ADB] App is not installed
[AndroidDriver] Apk is not yet installed
[AndroidDriver] installing apk from remote
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āmkdirā,"-p","/data/local/tmp"]
[AndroidDriver] Clearing out any existing remote apks with the same hash
[debug] [AndroidDriver] Removing any old apks
[debug] [AndroidDriver] Except [ā8e431a8da3b643581864d3ea5f739fe2ā]
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,ālsā,"/data/local/tmp/*.apk"]
[AndroidDriver] Will remove /data/local/tmp/528e2c0a377acc7792bcb08d60b687d9.apk
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,ārmā,"/data/local/tmp/528e2c0a377acc7792bcb08d60b687d9.apk"]
[AndroidDriver] Pushing com.blah.blah to device. Will wait up to 90000 milliseconds before aborting
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āpushā,"/pathTo/app.apk","/data/local/tmp/8e431a8da3b643581864d3ea5f739fe2.apk"]
[debug] [ADB] Uninstalling com.blah.blah
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āamā,āforce-stopā,ācom.blah.blahā]
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āuninstallā,ācom.blah.blahā]
[ADB] App was not uninstalled, maybe it wasnāt on device?
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āpmā,āinstallā,"-r","/data/local/tmp/8e431a8da3b643581864d3ea5f739fe2.apk"]
[debug] [AndroidDriver] Extracting strings from apk /pathTo/app.apk null /var/folders/n3/cqw987rs0n58txvdnkgssb3w0000gn/T/com.blah.blah
[debug] [ADB] Extracting strings for language: default
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āgetpropā,āpersist.sys.languageā]
[debug] [ADB] Current device property āpersist.sys.languageā:
[debug] [ADB] No strings.xml for language āā, getting default strings.xml
[debug] [ADB] Reading strings from converted strings.json
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āpushā,"/var/folders/n3/cqw987rs0n58txvdnkgssb3w0000gn/T/com.blah.blah/strings.json","/data/local/tmp"]
[ADB] Checking whether adb is present
[ADB] Using adb from /Applications/AndroidDev/sdk/platform-tools/adb
[debug] [ADB] Forwarding system: 4724 to device: 4724
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: [āforwardā,ātcp:4724ā,ātcp:4724ā]
[debug] [UiAutomator] Starting UiAutomator
[debug] [UiAutomator] Moving to state āstartingā
[debug] [UiAutomator] Parsing uiautomator jar
[debug] [UiAutomator] Found jar name: āAppiumBootstrap.jarā
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: [āpushā,"/usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar","/data/local/tmp/"]
[ADB] Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb forward tcp:4724 tcp:4724ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}
at Object.wrappedLogger.errorAndThrow (lib/logger.js:60:13)
at ADB.execFunc$ (lib/tools/system-calls.js:188:11)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at run (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:104:47)
at /usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:115:28
at flush (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
at process._tickCallback (node.js:355:11)
[Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb forward tcp:4724 tcp:4724ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}]
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: [āforwardā,ātcp:4724ā,ātcp:4724ā]
[ADB] Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}
at Object.wrappedLogger.errorAndThrow (lib/logger.js:60:13)
at ADB.execFunc$ (lib/tools/system-calls.js:188:11)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at run (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:104:47)
at /usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:115:28
at flush (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
at process._tickCallback (node.js:355:11)
[Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}]
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: [āpushā,"/usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar","/data/local/tmp/"]
[ADB] Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb forward tcp:4724 tcp:4724ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}
at Object.wrappedLogger.errorAndThrow (lib/logger.js:60:13)
at ADB.execFunc$ (lib/tools/system-calls.js:188:11)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at run (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:104:47)
at /usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:115:28
at flush (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
at process._tickCallback (node.js:355:11)
[Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb forward tcp:4724 tcp:4724ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}]
[ADB] Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}
at Object.wrappedLogger.errorAndThrow (lib/logger.js:60:13)
at ADB.execFunc$ (lib/tools/system-calls.js:188:11)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at run (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:104:47)
at /usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:115:28
at flush (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
at process._tickCallback (node.js:355:11)
[Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}]
[UiAutomator] Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}
at Object.wrappedLogger.errorAndThrow (lib/logger.js:60:13)
at ADB.execFunc$ (lib/tools/system-calls.js:188:11)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at run (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:104:47)
at /usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:115:28
at flush (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
at process._tickCallback (node.js:355:11)
[Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}]
[AndroidBootstrap] Error: Error occured while starting AndroidBootstrap. Original error: Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}
at Object.wrappedLogger.errorAndThrow (lib/logger.js:60:13)
at AndroidBootstrap.start$ (lib/bootstrap.js:89:11)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at run (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:104:47)
at /usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:115:28
at flush (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
at process._tickCallback (node.js:355:11)
[Error: Error occured while starting AndroidBootstrap. Original error: Error: Error executing adbExec. Original error: Command ā/Applications/AndroidDev/sdk/platform-tools/adb push /usr/local/lib/node_modules/appium/node_modules/appium-android-driver/node_modules/appium-android-bootstrap/bootstrap/bin/AppiumBootstrap.jar /data/local/tmp/ā exited with code 1{āstdoutā:"",āstderrā:āerror: more than one device/emulator\nā,ācodeā:1}]
[debug] [AndroidDriver] Shutting down Android driver
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āamā,āforce-stopā,ācom.blah.blahā]
[debug] [ADB] Pressing the HOME button
[debug] [ADB] Getting connected devicesā¦
[debug] [ADB] 2 device(s) connected
[debug] [ADB] Running /Applications/AndroidDev/sdk/platform-tools/adb with args: ["-s",āTA0930ALF7ā,āshellā,āinputā,ākeyeventā,3]
[debug] [Logcat] Stopping logcat capture
[debug] [UiAutomator] Shutting down UiAutomator
[debug] [UiAutomator] Moving to state āstoppingā
[MJSONWP] Encountered internal error running command: TypeError: Cannot read property āstopā of undefined
at UiAutomator.shutdown$ (lib/uiautomator.js:69:20)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at enqueueResult (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:185:17)
at new Promise (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:197:7)
at AsyncIterator.enqueue (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:184:16)
at AsyncIterator.prototype.(anonymous function) [as next] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at Object.runtime.async (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:209:12)
at UiAutomator.shutdown (lib/uiautomator.js:66:18)
at AndroidBootstrap.shutdown$ (lib/bootstrap.js:140:28)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at enqueueResult (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:185:17)
at new Promise (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:197:7)
at AsyncIterator.enqueue (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:184:16)
at AsyncIterator.prototype.(anonymous function) [as next] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at Object.runtime.async (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:209:12)
at AndroidBootstrap.shutdown (lib/bootstrap.js:129:18)
at AndroidDriver.deleteSession$ (lib/driver.js:276:28)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
at run (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:104:47)
at /usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/es6.promise.js:115:28
at flush (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
at process._tickCallback (node.js:355:11)
[HTTP] <-- POST /wd/hub/session 500 17963.897 ms - 177
^C