Settings_apk-debug.apk and unlock_apk-debug.apk fail to install

I am trying to test an Android app with Appium (version 1.5.3) and the Android emulator, but each time I run my test script, Appium is unable to install either settings_apk-debug.apk or unlock_apk-debug.apk. I have tried using the Android emulator with OS versions 4.4.2 (API level 19), 5.0 (API level 20), 5.0.1 (API level 21) and 5.1.1 (API level 22) - NONE OF THEM WORK. Below, you can see the 2 commands (from Appium logs) which Appium keeps getting stuck at:

[debug] [ADB] Running /Users/ysxb111/Library/Android/sdk/platform-tools/adb with args: ["-P",5037,"-s",“”,“install”,"/Applications/"]

[debug] [ADB] Running /Users/ysxb111/Library/Android/sdk/platform-tools/adb with args: ["-P",5037,"-s",“”,“install”,"/Applications/"]

Please do let me know if there is any way to fix this problem. I have been trying to resolve this for over a week, and would sincerely appreciate your guidance ASAP!

What’s the error reported in the server log? Without that, I can only guess what the problem is.

Try uninstalling the two apps before you run your automation

adb uninstall io.appium.settings
adb uninstall io.appium.unlock

If that fixes the problem, you have a workaround. Failing that, I’ll await the error messages from the server log.

1 Like

Already tried doing that, but it doesn’t fix the problem :frowning: Literally got stuck on the same command again:

[debug] [AndroidDriver] Pushing settings apk to device…

[debug] [ADB] Running /Users/ysxb111/Library/Android/sdk/platform-tools/adb with args: ["-P",5037,"-s",“emulator-5554”,“install”,"/Applications/"]

It gets stuck at the above command so there is no error message after that command in the Appium logs :confused:

What happens when you run the command manually?

/Users/ysxb111/Library/Android/sdk/platform-tools/adb -P 5037 -s emulator-5554 install /Applications/

Is there are reason you are using a non-default port for Appium, i.e. 4723?

Hi All,

Can someone please help to resolve this error.?

An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: ‘Command ‘/Users/user1/Library/Android/sdk/platform-tools/adb -P 5037 -s RF8M33VNBVK install /Applications/’ exited with code 1’; Stderr: ‘adb: failed to install /Applications/ Failure [INSTALL_FAILED_VERSION_DOWNGRADE]’; Code: ‘1’