Get an adbExec error after trying to create session in Appium Inspector - appium

I am a newbie in the Appium, and I get such error while trying to start a session through the Appium Inspector:
Failed to create a session.
An unknown server-side error occurred while processing the command.
Original error: Error executing adbExec.
Original error: 'Command 'C:\\Users\\xukin\\AppData\\Local\\Android\\Sdk\\platform-tools\\adb.exe -P 5037 -s emulator-5554 install -g C:\\Windows\\system32\\node_modules\\appium-uiautomator2-driver\\node_modules\\io.appium.settings\\apks\\settings_apk-debug.apk' exited with code 1';
Command output:
adb: failed to stat C:\Windows\system32\node_modules\appium-uiautomator2-driver\node_modules\io.appium.settings\apks\settings_apk-debug.apk: No such file or directory
Capabilities:
{
"platformName": "Android",
"appium:platformVersion": "12",
"appium:deviceName": "Pixel XL",
"appium:app": "C:/Users/xukin/OneDrive/Документы/app-release.apk",
"appium:automationName": "UIAutomator2",
"appium:udid": "emulator-5554"
}
I looked at this path, and the file was there. Someone knows what's the problem?

Related

An unknown server-side error occurred while processing the command. Original error: multi-disk zip files are not supported: found disk number: 8224

When I try to create appium server, i get this error
An unknown server-side error occurred while processing the command. Original error: multi-disk zip files are not supported: found disk number: 8224
Appium v1.17.1
{
"platformName": "Android",
"deviceName": "Any device name",
"app": "C:\Users\A196673\OneDrive - DEKRA SE\Desktop\apk\ApiDemos-debug.apk",
"udid": "emulator-5554",
"autmationName": "UiAutomator2"
}
i installed everything good but can not create server

Problem In Opening Appium Inspector with calculator seesion

"deviceName": "Moto C Plus",
"udid": "ZZ2222MGJM",
"platformName": "Android",
"platformVersion": "7.0",
"appPackage": "com.google.android.calculator",
"appActivity": "com.android.calculator2.Calculator"
when click on startSession button
error :
Error
An unknown server-side error occurred while processing the command. Original error: zipAlignApk failed. Original error: Command 'C:\Users\ANIL\Desktop\android-sdk\platform-tools\zipalign.exe -f 4 C:\Users\ANIL\AppData\Local\Temp\20191017-3868-paf3kz.h4yu\appium-uiautomator2-server-debug-androidTest.apk C:\Users\ANIL\AppData\Local\Temp\20191017-3868-1e9g3nn.xgdch\appium.tmp' exited with code 3221225781. Stdout: ''; Stderr: ''
I think you need to add the automationName parameter to your desired capabilities here. Something like:
automationName: UiAutomator1
Or
automationName: UiAutomator2
You can read about the automationName parameter under the Appium docs: http://appium.io/docs/en/writing-running-appium/caps/
It basically tells Appium which device-native automation framework to use.

Appium server returns "Error : Closed" with Code 1

I am starting to use Appium Desktop for Mobile Testing.
After the preliminary setup where I set the path and environment variables and defining the desired capabilities, clicking on "Start Session" button result in this message:
"An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: 'Command 'C\:\\Users\\test-PC\\AppData\\Local\\Android\\Sdk\\platform-tools\\adb.exe -P 5037 -s emulator-5554 shell pm list packages com.mol.molwallet' exited with code 1'; Stderr: 'error: closed'; Code: '1'.
Is there any way to find out what causes the "Closure" ? I am using Bluestack as the emulator.

Appium - iOS - Error writing xctestrun file: Error Domain=NSCocoaErrorDomain Code=4

I'm trying to connect Appium 1.12.1 to a physical iOS device with Automatic Server. These are the capabilities I am trying:
{
"browserName": "Safari",
"platformName": "iOS",
"platformVersion": "12.1",
"deviceName": "iPhone 6",
"automationName": "XCUITest",
"startIWDP": true,
"udid": "auto"
}
I am getting a lengthy error that starts with:
An unknown server-side error occurred while processing the command. Original error: Unable to launch WebDriverAgent because of xcodebuild failure: "xcodebuild failed with code 65 xcodebuild error message: 2019-04-09 10:14:08.626 xcodebuild[22198:212737] Error writing xctestrun file: Error Domain=NSCocoaErrorDomain Code=4 "The folder “WebDriverAgentRunner_iphoneos12.2-arm64.xctestrun” doesn’t exist."
I had the same problem.
In "/Users/YOUR_NAME/Library/Developer/Xcode/DerivedData/" I have two folders:
WebDriverAgent-akxhdiizyykdxefsthlnfyomlaiz
WebDriverAgent-ciegwgvxzxdrqthilmrmczmqvrgu
And Appium tried take the folder from WebDriverAgent-akxhdiizyykdxefsthlnfyomlaiz but need WebDriverAgent-ciegwgvxzxdrqthilmrmczmqvrgu.
I copied from WebDriverAgent-ciegwgvxzxdrqthilmrmczmqvrgu to WebDriverAgent-akxhdiizyykdxefsthlnfyomlaiz and now all work good.

Cannot install. ipa in iOS real device with appium

I am currently not able to install the .ipa file with appium.
I am able to install with ideviceinstaller manually with the command ideviceinstaller -i abc.ipa
but in appium, when I run my cucumber tests, I get the following error, when i tries to install,
Encountered internal error running command: Error: Command failed:
ideviceinstaller -u udid -i
/var/folders/58/bqk7r15x7hv_l35vll1hg5_w0000gp/T/2017311-19876-
1upzlv/Payload/abc.app
/bin/sh: -c: line 0: unexpected EOF while looking for matching `''
/bin/sh: -c: line 1: syntax error: unexpected end of file
at ChildProcess.exithandler (child_process.js:202:12)
at emitTwo (events.js:100:13)
at ChildProcess.emit (events.js:185:7)
at maybeClose (internal/child_process.js:850:16)
at Socket.<anonymous> (internal/child_process.js:323:11)
at emitOne (events.js:90:13)
at Socket.emit (events.js:182:7)
at Pipe._onclose (net.js:475:12)
My env.rb file is
require "appium_lib"
def caps
{
caps:{ deviceName: "iPhone",
platformName: "iOS",
app: (File.join(File.dirname(__FILE__), "abc.ipa")),
bundleId: "com.abc.abc",
newCommandTimeout: "3600",
appium_lib: { wait: 20,
debug: false
}
}
}
end
def server_url
'http://0.0.0.0:4723/wd/hub'
end
Appium::Driver.new(caps)
Appium.promote_appium_methods Object
Appears like the Appium cannot handle the ' in the path of the .app and has been acknowledged by the appium team for the fix in iOS in 1.5.3 version.

Resources