Unable to start app error in Mobile Testing

Hi Everyone, I am trying to run the Testcases from the Project which was created by my colleague and its throwing the below error …i checked the Log file and it shows his System path while its running on my machine. So i think the problem is with that path but i am unsure where that path is exactly coming from in the project. Or may be there can be different issue. Is there anything we need to change in the project? So has anyone had experienced this before or can anyone help me resolve this problem.
Below i am attaching the console Error and Log file. Please help i have tried many things but unable to resolve.
Thanks.
Console Error:
=============== ROOT CAUSE =====================
Caused by: com.kms.katalon.core.exception.StepFailedException: Unable to start app at: ‘C:\QA_Automation\Katalon_Projects\TMM\SQA-SVN\Trifecta Mobile Apps\ism-2.0.0-build-007.apk’ (Root cause: org.openqa.selenium.SessionNotCreatedException: Unable to create a new remote session. Please check the server log for more details. Original error: An unknown server-side error occurred while processing the command. Original error: Cannot start the ‘com.trifecta.ismobilev2’ application. Visit appium/activity-startup.md at master · appium/appium · GitHub for troubleshooting. Original error: Error executing adbExec. Original error: ‘Command ‘C:\Users\bhagyashree.patel\.katalon\tools\android_sdk\platform-tools\adb.exe -P 5037 -s 0316035883981404 shell am start -W -n com.trifecta.ismobilev2/host.exp.exponent.MainActivity -S -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -f 0x10200000’ timed out after 20000ms’. Try to increase the 20000ms adb execution timeout represented by ‘adbExecTimeout’ capability

For trouble shooting, please visit: https://docs.katalon.com/katalon-studio/docs/troubleshoot-common-execution-exceptions-web-test.html

Log File :
e[35m[Appium]e[39m Welcome to Appium v1.18.1
e[35m[Appium]e[39m Non-default server args:
e[35m[Appium]e[39m port: 52224
e[35m[Appium]e[39m loglevel: info
e[35m[Appium]e[39m tmpDir: C:\Users\BOB~1.HAG\AppData\Local\Temp\Katalon\Appium\Temp1606259077541
e[35m[Appium]e[39m chromedriverPort: 52225
e[35m[Appium]e[39m Deprecated server args:
e[35m[Appium]e[39m e[31m–chromedriver-porte[39m => --default-capabilities ‘{“chromedriverPort”:52225}’
e[35m[Appium]e[39m Default capabilities, which will be added to each request unless overridden by desired capabilities:
e[35m[Appium]e[39m chromedriverPort: 52225
e[35m[Appium]e[39m Appium REST http interface listener started on 0.0.0.0:52224
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/statuse[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/status e[39me[32m200e[39m e[90m9 ms - 68e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/statuse[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/status e[39me[32m200e[39m e[90m1 ms - 68e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mPOSTe[39m e[37m/wd/hub/sessione[39m
e[35m[HTTP]e[39m e[90m{“desiredCapabilities”:{“app”:“C:\QA_Automation\Katalon_Projects\TMM\SQA-SVN\Trifecta Mobile Apps\ism-2.0.0-build-007.apk”,“appWaitActivity “:“com.",“noReset”:true,“deviceId”:“710KPPB0176960”,“deviceName”:“Google Pixel 2 XL (Android 11)”,“fullReset”:false,“platform”:“ANDROID”,“newCommandTimeout”:1800,“platformVersion”:“11”,“automationName”:“uiautomator2”,“autoGrantPermissions”:true,“platformName”:“Android”,“udid”:“710KPPB0176960”,“systemPort”:52234},“capabilities”:{“firstMatch”:[{“appium:app”:“C:\QA_Automation\Katalon_Projects\TMM\SQA-SVN\Trifecta Mobile Apps\ism-2.0.0-build-007.apk”,"appWaitActivity ":"com.”,“appium:autoGrantPermissions”:true,“appium:automationName”:“uiautomator2”,“deviceId”:“710KPPB0176960”,“appium:deviceName”:“Google Pixel 2 XL (Android 11)”,“appium:fullReset”:false,“appium:newCommandTimeout”:1800,“appium:noReset”:true,“platform”:“ANDROID”,“platformName”:“android”,“appium:platformVersion”:“11”,“appium:systemPort”:52234,“appium:udid”:“710KPPB0176960”}]}}e[39m
e[35m[BaseDriver]e[39m The following capabilities are not standard capabilities and should have an extension prefix:
e[35m[BaseDriver]e[39m appWaitActivity
e[35m[BaseDriver]e[39m deviceId
e[35m[BaseDriver]e[39m platform
e[35m[BaseDriver]e[39m chromedriverPort
e[35m[Appium]e[39m Appium v1.18.1 creating new AndroidUiautomator2Driver (v1.56.1) session
e[35m[BaseDriver]e[39m The following capabilities were provided, but are not recognized by Appium:
e[35m[BaseDriver]e[39m appWaitActivity
e[35m[BaseDriver]e[39m deviceId
e[35m[BaseDriver]e[39m platform
e[35m[BaseDriver]e[39m Session created with session id: 5bfa5b38-c083-4a39-be00-03b008e44b25
e[35m[BaseDriver]e[39m Using local app ‘C:\QA_Automation\Katalon_Projects\TMM\SQA-SVN\Trifecta Mobile Apps\ism-2.0.0-build-007.apk’
e[35m[ADB]e[39m Found 1 ‘build-tools’ folders under ‘C:\Users\bob.haghighat.katalon\tools\android_sdk’ (newest first):
e[35m[ADB]e[39m C:/Users/bob.haghighat/.katalon/tools/android_sdk/build-tools/29.0.2
e[35m[ADB]e[39m Using ‘adb.exe’ from ‘C:\Users\bob.haghighat.katalon\tools\android_sdk\platform-tools\adb.exe’
e[35m[AndroidDriver]e[39m Retrieving device list
e[35m[AndroidDriver]e[39m Using device: 710KPPB0176960
e[35m[ADB]e[39m Using ‘adb.exe’ from ‘C:\Users\bob.haghighat.katalon\tools\android_sdk\platform-tools\adb.exe’
e[35m[ADB]e[39m Getting device platform version
e[35m[UiAutomator2]e[39m Relaxing hidden api policy
e[35m[ADB]e[39m Package name: ‘com.trifecta.ismobilev2’
e[35m[ADB]e[39m Main activity name: ‘host.exp.exponent.MainActivity’
e[35m[ADB]e[39m Using ‘apksigner.jar’ from ‘C:\Users\bob.haghighat.katalon\tools\android_sdk\build-tools\29.0.2\lib\apksigner.jar’
e[35m[UiAutomator2]e[39m Server packages are not going to be (re)installed
e[35m[UiAutomator2]e[39m Starting UIAutomator2 server 4.12.2
e[35m[UiAutomator2]e[39m Using UIAutomator2 server from ‘C:\Users\bob.haghighat\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.12.2.apk’ and test from ‘C:\Users\bob.haghighat\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk’
e[35m[UiAutomator2]e[39m Waiting up to 30000ms for UiAutomator2 to be online…
e[35m[WD Proxy]e[39m socket hang up
e[35m[WD Proxy]e[39m socket hang up
e[35m[WD Proxy]e[39m Determined the downstream protocol as ‘W3C’
e[35m[AndroidDriver]e[39m Screen already unlocked, doing nothing
e[35m[UiAutomator2]e[39m Starting 'com.trifecta.ismobilev2/host.exp.exponent.MainActivity and waiting for ‘com.trifecta.ismobilev2/host.exp.exponent.MainActivity’
e[35m[Appium]e[39m New AndroidUiautomator2Driver session created successfully, session 5bfa5b38-c083-4a39-be00-03b008e44b25 added to master session list
e[35m[HTTP]e[39m e[37m<-- POST /wd/hub/session e[39me[32m200e[39m e[90m12935 ms - 1473e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25e[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25 e[39me[32m200e[39m e[90m33 ms - 1427e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25e[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25 e[39me[32m200e[39m e[90m16 ms - 1427e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/statuse[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/status e[39me[32m200e[39m e[90m2 ms - 68e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mPOSTe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/timeoutse[39m
e[35m[HTTP]e[39m e[90m{“implicit”:60000}e[39m
e[35m[HTTP]e[39m e[37m<-- POST /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/timeouts e[39me[32m200e[39m e[90m5 ms - 14e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/sourcee[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[W3C (5bfa5b38)]e[39m Driver proxy active, passing request on via HTTP proxy
e[35m[WD Proxy]e[39m Replacing sessionId 01105bba-74a8-4879-8951-abb7902fea53 with 5bfa5b38-c083-4a39-be00-03b008e44b25
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/source e[39me[32m200e[39m e[90m142 ms - 4475e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/screenshote[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/screenshot e[39me[32m200e[39m e[90m724 ms - 278522e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/sourcee[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[W3C (5bfa5b38)]e[39m Driver proxy active, passing request on via HTTP proxy
e[35m[WD Proxy]e[39m Replacing sessionId 01105bba-74a8-4879-8951-abb7902fea53 with 5bfa5b38-c083-4a39-be00-03b008e44b25
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/source e[39me[32m200e[39m e[90m461 ms - 27465e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/screenshote[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/screenshot e[39me[32m200e[39m e[90m797 ms - 198458e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mPOSTe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/elementse[39m
e[35m[HTTP]e[39m e[90m{“using”:”-android uiautomator”,“value”:“new UiSelector().className(“android.widget.TextView”).text(“Ignored”).packageName(“host.exp.exponent”).enabled(true).clickable(false).longClickable(false).checkable(false).checked(false).focusable(false).focused(false).scrollable(false).selected(false).index(1)”}e[39m
e[35m[HTTP]e[39m e[37m<-- POST /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/elements e[39me[32m200e[39m e[90m327 ms - 139e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/sourcee[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[W3C (5bfa5b38)]e[39m Driver proxy active, passing request on via HTTP proxy
e[35m[WD Proxy]e[39m Replacing sessionId 01105bba-74a8-4879-8951-abb7902fea53 with 5bfa5b38-c083-4a39-be00-03b008e44b25
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/source e[39me[32m200e[39m e[90m116 ms - 6853e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/screenshote[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/screenshot e[39me[32m200e[39m e[90m793 ms - 183682e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mPOSTe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/elementse[39m
e[35m[HTTP]e[39m e[90m{“using”:“id”,“value”:“android:id/text1”}e[39m
e[35m[HTTP]e[39m e[37m<-- POST /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25/elements e[39me[32m200e[39m e[90m94 ms - 139e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[BaseDriver]e[39m Shutting down because we waited 1800 seconds for a command
e[35m[Appium]e[39m Closing session, cause was ‘New Command Timeout of 1800 seconds expired. Try customizing the timeout using the ‘newCommandTimeout’ desired capability’
e[35m[Appium]e[39m Removing session ‘5bfa5b38-c083-4a39-be00-03b008e44b25’ from our master session list
e[35m[UiAutomator2]e[39m Restoring hidden api policy to the device default configuration
e[35m[HTTP]e[39m e[37m–>e[39m e[37mDELETEe[39m e[37m/wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25e[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- DELETE /wd/hub/session/5bfa5b38-c083-4a39-be00-03b008e44b25 e[39me[33m404e[39m e[90m140 ms - 2524e[39m
e[35m[HTTP]e[39m e[90me[39m

@bhagyashree.patel

Please try the suggestion in this post:

@duyluong I tried the above Desired capability but the same error appears. here is the the complete error log (I have added in the file because it was not allowing me to post more than 32000 characters)please see the error in below attached file ISMobileError.txt (78.2 KB) .
P.S. - Katalon Sample project works on my machine.But this project is having the above errors/exceptions
Your help will be highly appreciated. Thank you

Hi @bhagyashree.patel,
Option 1:
Please run this command on the terminal. If this commands succeeds manually and starts the necessary application on the device then it will work for Katalon/Appium as well.

C:\Users\bhagyashree.patel\.katalon\tools\android_sdk\platform-tools\adb.exe -P 5037 -s 0316035883981404 shell am start -W -n com.trifecta.ismobilev2/host.exp.exponent.MainActivity -S -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -f 0x10200000

Option 2:
You can install the apk on your phone and use Start With Application ID