##Waiting up to 20000ms for UiAutomator2 to be online...
And UIAutomator2 server never goes up after some retries.
For 100+ test cases executing in parallel , sometimes UIAutomator2 server goes down and the execution halts.
Solution:
Requires uninstallation of UIAutomator server and test apk from the device.
This issues happens once in 10 times for parallel execution
Environment
UIAutomator2 apk version : 1.8
Appium desktop 1.7
ANdroid device : 6.0.1
java client :5
OS : Windows
Code To Reproduce Issue [ Good To Have ]
Try closing you old appium session forcefully , for the next session UIAutomator2 fails to go online.
Logs
[DEBUG] 2017-12-13 13:16:39,910 com.qklab.appium.Initiator$1 run - APPIUM: [HTTP] --> GET /wd/hub/status {} [DEBUG] 2017-12-13 13:16:39,910 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [MJSONWP] Calling AppiumDriver.getStatus() with args: [] [DEBUG] 2017-12-13 13:16:39,913 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [MJSONWP] Responding to client with driver.getStatus() result: {"build":{"version":"1.7.1","revision":null}} [DEBUG] 2017-12-13 13:16:39,914 com.qklab.appium.Initiator$1 run - APPIUM: [HTTP] <-- GET /wd/hub/status 200 3 ms - 83 [DEBUG] 2017-12-13 13:16:40,433 com.qklab.appium.Initiator$1 run - APPIUM: [HTTP] --> POST /wd/hub/session {"desiredCapabilities":{"appPackage":"com.phonepe.app","appActivity":"com.phonepe.app.ui.activity.Navigator_MainActivity","acceptSslCerts":true,"noReset":"true","newCommandTimeout":"1800","platformVersion":"6.0.1","loggingPrefs":{"driver":"SEVERE"},"automationName":"uiautomator2","udid":"df7cc4df","platformName":"Android","deviceName":"Samsung","systemPort":"41274"},"requiredCapabilities":{},"capabilities":{"desiredCapabilities":{"appPackage":"com.phonepe.app","appActivity":"com.phonepe.app.ui.activity.Navigator_MainActivity","acceptSslCerts":true,"noReset":"true","newCommandTimeout":"1800","platformVersion":"6.0.1","loggingPrefs":{"driver":"SEVERE"},"automationName":"uiautomator2","udid":"df7cc4df","platformName":"Android","deviceName":"Samsung","systemPort":"41274"},"requiredCapabilities":{},"alwaysMatch":{"platformName":"Android"},"firstMatch":[]}} [DEBUG] 2017-12-13 13:16:40,433 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [MJSONWP] Calling AppiumDriver.createSession() with args: [{"appPackage":"com.phonepe.app","appActivity":"com.phonepe.app.ui.activity.Navigator_MainActivity","acceptSslCerts":true,"noReset":"true","newCommandTimeout":"1800","platformVersion":"6.0.1","loggingPrefs":{"driver":"SEVERE"},"automationName":"uiautomator2","udid":"df7cc4df","platformName":"Android","deviceName":"Samsung","systemPort":"41274"},{},{"desiredCapabilities":{"appPackage":"com.phonepe.app","appActivity":"com.phonepe.app.ui.activity.Navigator_MainActivity","acceptSslCerts":true,"noReset":"true","newCommandTimeout":"1800","platformVersion":"6.0.1","loggingPrefs":{"driver":"SEVERE"},"automationName":"uiautomator2","udid":"df7cc4df","platformName":"Android","deviceName":"Samsung","systemPort":"41274"},"requiredCapabilities":{},"alwaysMatch":{"platformName":"Android"},"firstMatch":[]}] [DEBUG] 2017-12-13 13:16:40,434 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [BaseDriver] Event 'newSessionRequested' logged at 1513151200434 (13:16:40 GMT+0530 (India Standard Time)) [DEBUG] 2017-12-13 13:16:40,437 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] Creating new AndroidUiautomator2Driver (v0.6.5) session [DEBUG] 2017-12-13 13:16:40,437 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] Capabilities: [DEBUG] 2017-12-13 13:16:40,438 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] appPackage: 'com.phonepe.app' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] appActivity: 'com.phonepe.app.ui.activity.Navigator_MainActivity' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] acceptSslCerts: true [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] noReset: 'true' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] newCommandTimeout: '1800' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] platformVersion: '6.0.1' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] loggingPrefs: { driver: 'SEVERE' } [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] automationName: 'uiautomator2' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] udid: 'df7cc4df' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] platformName: 'Android' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] deviceName: 'Samsung' [DEBUG] 2017-12-13 13:16:40,439 com.qklab.appium.Initiator$1 run - APPIUM: [Appium] systemPort: '41274' [DEBUG] 2017-12-13 13:16:40,443 com.qklab.appium.Initiator$1 run - APPIUM: [BaseDriver] Capability 'noReset' changed from string to boolean. This may cause unexpected behavior [DEBUG] 2017-12-13 13:16:40,444 com.qklab.appium.Initiator$1 run - APPIUM: [BaseDriver] Capability 'newCommandTimeout' changed from string ('1800') to integer (1800). This may cause unexpected behavior [DEBUG] 2017-12-13 13:16:40,447 com.qklab.appium.Initiator$1 run - APPIUM: [BaseDriver] The following capabilities were provided, but are not recognized by appium: acceptSslCerts, loggingPrefs, systemPort. [DEBUG] 2017-12-13 13:16:40,448 com.qklab.appium.Initiator$1 run - APPIUM: [BaseDriver] Session created with session id: 5fcca401-3d26-4120-b84f-003aa15951b3 [DEBUG] 2017-12-13 13:16:40,450 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [AndroidDriver] Getting Java version [DEBUG] 2017-12-13 13:16:40,524 com.qklab.appium.Initiator$1 run - APPIUM: [AndroidDriver] Java version is: 1.8.0_51 [DEBUG] 2017-12-13 13:16:40,524 com.qklab.appium.Initiator$1 run - APPIUM: [DEBUG] 2017-12-13 13:16:40,527 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] Checking whether adb is present [DEBUG] 2017-12-13 13:16:40,529 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] Using adb.exe from D:\android-sdk\platform-tools\adb.exe [DEBUG] 2017-12-13 13:16:40,529 com.qklab.appium.Initiator$1 run - APPIUM: [AndroidDriver] Retrieving device list [DEBUG] 2017-12-13 13:16:40,529 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Trying to find a connected android device [DEBUG] 2017-12-13 13:16:40,530 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:40,549 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:40,550 com.qklab.appium.Initiator$1 run - APPIUM: [AndroidDriver] Using device: df7cc4df [DEBUG] 2017-12-13 13:16:40,551 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] Checking whether adb is present [DEBUG] 2017-12-13 13:16:40,552 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] Using adb.exe from D:\android-sdk\platform-tools\adb.exe [DEBUG] 2017-12-13 13:16:40,552 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Setting device id to df7cc4df [DEBUG] 2017-12-13 13:16:40,552 com.qklab.appium.Initiator$1 run - APPIUM: [AndroidDriver] No app sent in, not parsing package/activity [DEBUG] 2017-12-13 13:16:40,553 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] Getting device platform version [DEBUG] 2017-12-13 13:16:40,553 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:40,571 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:40,574 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","getprop","ro.build.version.release"] [DEBUG] 2017-12-13 13:16:40,646 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Current device property 'ro.build.version.release': 6.0.1 [DEBUG] 2017-12-13 13:16:40,646 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:40,664 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:40,664 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","wm","size"] [DEBUG] 2017-12-13 13:16:42,170 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:42,188 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:42,189 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","getprop","ro.product.model"] [DEBUG] 2017-12-13 13:16:42,241 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Current device property 'ro.product.model': SM-J510FN [DEBUG] 2017-12-13 13:16:42,242 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:42,259 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:42,259 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","getprop","ro.product.manufacturer"] [DEBUG] 2017-12-13 13:16:42,312 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Current device property 'ro.product.manufacturer': samsung [DEBUG] 2017-12-13 13:16:42,313 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:42,331 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:42,331 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","am","force-stop","io.appium.uiautomator2.server"] [DEBUG] 2017-12-13 13:16:43,841 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] Checking whether aapt is present [DEBUG] 2017-12-13 13:16:43,842 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] Using aapt.exe from D:\android-sdk\build-tools\26.0.2\aapt.exe [DEBUG] 2017-12-13 13:16:43,859 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting install status for io.appium.uiautomator2.server [DEBUG] 2017-12-13 13:16:43,859 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:43,877 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:43,878 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","pm","list","packages","io.appium.uiautomator2.server"] [DEBUG] 2017-12-13 13:16:45,228 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] App is installed [DEBUG] 2017-12-13 13:16:45,228 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting install status for io.appium.uiautomator2.server.test [DEBUG] 2017-12-13 13:16:45,228 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:45,247 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:45,247 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","pm","list","packages","io.appium.uiautomator2.server.test"] [DEBUG] 2017-12-13 13:16:46,611 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] App is installed [DEBUG] 2017-12-13 13:16:46,612 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting package info for io.appium.uiautomator2.server [DEBUG] 2017-12-13 13:16:46,612 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:46,630 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:46,630 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","dumpsys","package","io.appium.uiautomator2.server"] [DEBUG] 2017-12-13 13:16:46,711 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [UiAutomator2] Waiting up to 20000ms for instrumentation 'io.appium.uiautomator2.server.test/android.support.test.runner.AndroidJUnitRunner' to be available [DEBUG] 2017-12-13 13:16:46,712 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:46,730 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:46,730 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","pm","list","instrumentation"] [DEBUG] 2017-12-13 13:16:47,992 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [UiAutomator2] Instrumentation 'io.appium.uiautomator2.server.test/android.support.test.runner.AndroidJUnitRunner' available [DEBUG] 2017-12-13 13:16:47,993 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","wait-for-device"] [DEBUG] 2017-12-13 13:16:48,012 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:48,030 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:48,030 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","echo","ping"] [DEBUG] 2017-12-13 13:16:48,086 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [Logcat] Starting logcat capture [DEBUG] 2017-12-13 13:16:48,137 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [AndroidDriver] Pushing settings apk to device... [DEBUG] 2017-12-13 13:16:48,137 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Uninstalling and re-installing 'io.appium.settings' [DEBUG] 2017-12-13 13:16:48,138 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Uninstalling io.appium.settings [DEBUG] 2017-12-13 13:16:48,138 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting install status for io.appium.settings [DEBUG] 2017-12-13 13:16:48,138 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:48,156 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:48,156 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","pm","list","packages","io.appium.settings"] [DEBUG] 2017-12-13 13:16:49,858 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] App is installed [DEBUG] 2017-12-13 13:16:49,858 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:49,876 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:49,877 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","am","force-stop","io.appium.settings"] [DEBUG] 2017-12-13 13:16:51,384 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","uninstall","io.appium.settings"] [DEBUG] 2017-12-13 13:16:53,345 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] ADB command output: Success [DEBUG] 2017-12-13 13:16:53,345 com.qklab.appium.Initiator$1 run - APPIUM: [ADB] io.appium.settings was successfully uninstalled [DEBUG] 2017-12-13 13:16:53,346 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting install status for io.appium.settings [DEBUG] 2017-12-13 13:16:53,346 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:53,364 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:53,364 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","pm","list","packages","io.appium.settings"] [DEBUG] 2017-12-13 13:16:54,960 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] App is not installed [DEBUG] 2017-12-13 13:16:54,960 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] App 'D:\appium-desktop\resources\app\node_modules\appium\node_modules\io.appium.settings\app\build\outputs\apk\settings_apk-debug.apk' not installed. Installing [DEBUG] 2017-12-13 13:16:54,961 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","install","D:\appium-desktop\resources\app\node_modules\appium\node_modules\io.appium.settings\app\build\outputs\apk\settings_apk-debug.apk"] [DEBUG] 2017-12-13 13:16:57,640 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:57,659 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:57,659 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","getprop","ro.build.version.sdk"] [DEBUG] 2017-12-13 13:16:57,726 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Current device property 'ro.build.version.sdk': 23 [DEBUG] 2017-12-13 13:16:57,726 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Device API level: 23 [DEBUG] 2017-12-13 13:16:57,727 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:57,744 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:57,744 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","dumpsys","package","io.appium.settings"] [DEBUG] 2017-12-13 13:16:57,847 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:16:57,864 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:16:57,865 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","pm","dump","io.appium.settings"] [DEBUG] 2017-12-13 13:17:00,511 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Got the following command chunks to execute: pm,grant,io.appium.settings,android.permission.INTERNET,;,pm,grant,io.appium.settings,android.permission.CHANGE_NETWORK_STATE,;,pm,grant,io.appium.settings,android.permission.ACCESS_NETWORK_STATE,;,pm,grant,io.appium.settings,android.permission.READ_PHONE_STATE,;,pm,grant,io.appium.settings,android.permission.WRITE_SETTINGS,;,pm,grant,io.appium.settings,android.permission.CHANGE_WIFI_STATE,;,pm,grant,io.appium.settings,android.permission.ACCESS_WIFI_STATE,;,pm,grant,io.appium.settings,android.permission.ACCESS_FINE_LOCATION,;,pm,grant,io.appium.settings,android.permission.ACCESS_COARSE_LOCATION,;,pm,grant,io.appium.settings,android.permission.ACCESS_MOCK_LOCATION,;,pm,grant,io.appium.settings,android.permission.SET_ANIMATION_SCALE,; [DEBUG] 2017-12-13 13:17:00,511 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:00,583 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:00,584 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","pm","grant","io.appium.settings","android.permission.INTERNET",";","pm","grant","io.appium.settings","android.permission.CHANGE_NETWORK_STATE",";","pm","grant","io.appium.settings","android.permission.ACCESS_NETWORK_STATE",";","pm","grant","io.appium.settings","android.permission.READ_PHONE_STATE",";","pm","grant","io.appium.settings","android.permission.WRITE_SETTINGS",";","pm","grant","io.appium.settings","android.permission.CHANGE_WIFI_STATE",";","pm","grant","io.appium.settings","android.permission.ACCESS_WIFI_STATE",";","pm","grant","io.appium.settings","android.permission.ACCESS_FINE_LOCATION",";","pm","grant","io.appium.settings","android.permission.ACCESS_COARSE_LOCATION",";","pm","grant","io.appium.settings","android.permission.ACCESS_MOCK_LOCATION",";","pm","grant","io.appium.settings","android.permission.SET_ANIMATION_SCALE",";"] [DEBUG] 2017-12-13 13:17:15,008 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:15,027 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:15,027 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","ps"] [DEBUG] 2017-12-13 13:17:15,283 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Device API level: 23 [DEBUG] 2017-12-13 13:17:15,284 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:15,302 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:15,302 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","am","start","-W","-n","io.appium.settings/.Settings","-a","android.intent.action.MAIN","-c","android.intent.category.LAUNCHER","-f","0x10200000"] [DEBUG] 2017-12-13 13:17:17,594 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Device API level: 23 [DEBUG] 2017-12-13 13:17:17,594 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:17,612 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:17,613 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","appops","set","io.appium.settings","android:mock_location","allow"] [DEBUG] 2017-12-13 13:17:19,392 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [AndroidDriver] Pushing unlock helper app to device... [DEBUG] 2017-12-13 13:17:19,392 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","install","D:\appium-desktop\resources\app\node_modules\appium\node_modules\appium-unlock\bin\unlock_apk-debug.apk"] [DEBUG] 2017-12-13 13:17:21,287 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [UiAutomator2] Forwarding UiAutomator2 Server port 6790 to 41274 [DEBUG] 2017-12-13 13:17:21,287 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Forwarding system: 41274 to device: 6790 [DEBUG] 2017-12-13 13:17:21,287 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","forward","tcp:41274","tcp:6790"] [DEBUG] 2017-12-13 13:17:21,305 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:21,323 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:21,324 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","dumpsys","window"] [DEBUG] 2017-12-13 13:17:21,436 com.qklab.appium.Initiator$1 run - APPIUM: [AndroidDriver] Screen already unlocked, doing nothing [DEBUG] 2017-12-13 13:17:21,437 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [AndroidDriver] Extracting strings from apk null null C:\Users\TS90US~1\AppData\Local\Temp\4\com.phonepe.app [DEBUG] 2017-12-13 13:17:21,438 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Extracting strings for language: default [DEBUG] 2017-12-13 13:17:21,438 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Device API level: 23 [DEBUG] 2017-12-13 13:17:21,438 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:21,456 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:21,456 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","getprop","persist.sys.locale"] [DEBUG] 2017-12-13 13:17:21,544 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Current device property 'persist.sys.locale': en-GB [DEBUG] 2017-12-13 13:17:21,667 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] No strings.xml for language 'en', getting default strings.xml [DEBUG] 2017-12-13 13:17:21,809 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:21,827 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:21,828 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","rm","-rf","/data/local/tmp/strings.json"] [DEBUG] 2017-12-13 13:17:21,899 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [UiAutomator2] No app capability. Assuming it is already on the device [DEBUG] 2017-12-13 13:17:21,903 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] APK doesn't exist. null [DEBUG] 2017-12-13 13:17:21,904 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Getting connected devices... [DEBUG] 2017-12-13 13:17:21,921 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] 2 device(s) connected [DEBUG] 2017-12-13 13:17:21,921 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [ADB] Running 'D:\android-sdk\platform-tools\adb.exe' with args: ["-P",5037,"-s","df7cc4df","shell","am","force-stop","io.appium.uiautomator2.server"] [DEBUG] 2017-12-13 13:17:23,374 com.qklab.appium.Initiator$1 run - APPIUM: [UiAutomator2] Starting uiautomator2 server v0.1.8 [DEBUG] 2017-12-13 13:17:23,375 com.qklab.appium.Initiator$1 run - APPIUM: [UiAutomator2] Running command: 'adb -s df7cc4df shell am instrument -w io.appium.uiautomator2.server.test/android.support.test.runner.AndroidJUnitRunner' [DEBUG] 2017-12-13 13:17:23,377 com.qklab.appium.Initiator$1 run - APPIUM: [UiAutomator2] Waiting up to 20000ms for UiAutomator2 to be online... [DEBUG] 2017-12-13 13:17:23,378 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [JSONWP Proxy] Proxying [GET /status] to [GET http://localhost:41274/wd/hub/status] with no body [DEBUG] 2017-12-13 13:17:24,398 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [JSONWP Proxy] Proxying [GET /status] to [GET http://localhost:41274/wd/hub/status] with no body [DEBUG] 2017-12-13 13:17:25,402 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [JSONWP Proxy] Proxying [GET /status] to [GET http://localhost:41274/wd/hub/status] with no body [DEBUG] 2017-12-13 13:17:26,408 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [JSONWP Proxy] Proxying [GET /status] to [GET http://localhost:41274/wd/hub/status] with no body [DEBUG] 2017-12-13 13:17:27,411 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [JSONWP Proxy] Proxying [GET /status] to [GET http://localhost:41274/wd/hub/status] with no body [DEBUG] 2017-12-13 13:17:28,414 com.qklab.appium.Initiator$1 run - APPIUM: [debug] [JSONWP Proxy] Proxying [GET /status] to [GET http://localhost:41274/wd/hub/status] with no body