Exception in thread "main" org.openqa.selenium.WebDriverException: An unknown server-side error occurred while processing the command.
See original GitHub issueAppium version 1.8.0 Device Samsung Galaxy S4 (android 5.0.1) Java 1.8.0
My first test to check whether appium is working correct:
` import io.appium.java_client.android.AndroidDriver; import org.openqa.selenium.firefox.FirefoxDriver; import org.openqa.selenium.remote.DesiredCapabilities;
import java.net.MalformedURLException; import java.net.URL; import java.util.concurrent.TimeUnit;
public class Main{
public static void main (String[] args) throws MalformedURLException, InterruptedException {
DesiredCapabilities caps = new DesiredCapabilities();
caps.setCapability("deviceName", "6383a624");
caps.setCapability("platformName", "Android");
caps.setCapability("app", "C:\\Program Files (x86)\\Appium\\resources\\app\\node_modules\\appium-unlock\\bin\\unlock_apk-debug.apk");
AndroidDriver driver = new AndroidDriver(new URL("http://0.0.0.0:4723/wd/hub"), caps);
driver.quit();
}
}
`
When I run my first test I see below unknown server-side error:
Exception in thread “main” org.openqa.selenium.WebDriverException: An unknown server-side error occurred while processing the command. Original error: Error finding if process exists. Original error: cmd.join is not a function Build info: version: ‘3.6.0’, revision: ‘6fbf3ec767’, time: ‘2017-09-27T15:28:36.4Z’ System info: host: ‘MOBICA3732’, ip: ‘192.168.60.59’, os.name: ‘Windows 7’, os.arch: ‘amd64’, os.version: ‘6.1’, java.version: ‘10.0.1’ Driver info: driver.version: AndroidDriver remote stacktrace: UnknownError: An unknown server-side error occurred while processing the command. Original error: Error finding if process exists. Original error: cmd.join is not a function at getResponseForW3CError (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-base-driver\lib\protocol\errors.js:800:13) at asyncHandler$ (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-base-driver\lib\protocol\protocol.js:352:37) at tryCatch (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-base-driver\node_modules\babel-runtime\regenerator\runtime.js:67:40) at GeneratorFunctionPrototype.invoke [as _invoke] (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-base-driver\node_modules\babel-runtime\regenerator\runtime.js:315:22) at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-base-driver\node_modules\babel-runtime\regenerator\runtime.js💯21) at GeneratorFunctionPrototype.invoke (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-base-driver\node_modules\babel-runtime\regenerator\runtime.js:136:37) at <anonymous> at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:488) at org.openqa.selenium.remote.W3CHandshakeResponse.lambda$new$0(W3CHandshakeResponse.java:57) at org.openqa.selenium.remote.W3CHandshakeResponse.lambda$getResponseFunction$2(W3CHandshakeResponse.java:104) at org.openqa.selenium.remote.ProtocolHandshake.lambda$createSession$24(ProtocolHandshake.java:359) at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195) at java.base/java.util.Spliterators$ArraySpliterator.tryAdvance(Spliterators.java:958) at java.base/java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:127) at java.base/java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:502) at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:488) at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474) at java.base/java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:150) at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) at java.base/java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:543) at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:362) at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:136) at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:142) at io.appium.java_client.remote.AppiumCommandExecutor.execute(AppiumCommandExecutor.java:89) at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:586) at io.appium.java_client.DefaultGenericMobileDriver.execute(DefaultGenericMobileDriver.java:42) at io.appium.java_client.AppiumDriver.execute(AppiumDriver.java:1) at io.appium.java_client.android.AndroidDriver.execute(AndroidDriver.java:1) at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:217) at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:140) at io.appium.java_client.DefaultGenericMobileDriver.<init>(DefaultGenericMobileDriver.java:38) at io.appium.java_client.AppiumDriver.<init>(AppiumDriver.java:83) at io.appium.java_client.AppiumDriver.<init>(AppiumDriver.java:93) at io.appium.java_client.android.AndroidDriver.<init>(AndroidDriver.java:72) at Main.main(Main.java:18)
Logs from appium server:
The server is running
[Appium] Welcome to Appium v1.8.0 [Appium] Appium REST http interface listener started on 0.0.0.0:4723 [HTTP] --> POST /wd/hub/session [HTTP] {“desiredCapabilities”:{“app”:“C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk”,“platformName”:“Android”,“deviceName”:“6383a624”},“requiredCapabilities”:{},“capabilities”:{“desiredCapabilities”:{“app”:“C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk”,“platformName”:“Android”,“deviceName”:“6383a624”},“requiredCapabilities”:{},“alwaysMatch”:{“platformName”:“Android”},“firstMatch”:[]}} [MJSONWP] Calling AppiumDriver.createSession() with args: [{“app”:“C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk”,“platformName”:“Android”,“deviceName”:“6383a624”},{},{“desiredCapabilities”:{“app”:“C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk”,“platformName”:“Android”,“deviceName”:“6383a624”},“requiredCapabilities”:{},“alwaysMatch”:{“platformName”:“Android”},“firstMatch”:[]}] [BaseDriver] Event ‘newSessionRequested’ logged at 1526902861948 (13:41:01 GMT+0200 (Central European Daylight Time)) [Appium] Could not parse W3C capabilities: ‘deviceName’ can’t be blank. Falling back to JSONWP protocol. [Appium] The following capabilities were provided in the JSONWP desired capabilities that are missing in W3C capabilities: [“app”,“platformName”,“deviceName”]. Falling back to JSONWP protocol. [Appium] Creating new AndroidDriver (v2.6.0) session [Appium] Capabilities: [Appium] app: C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk [Appium] platformName: Android [Appium] deviceName: 6383a624 [BaseDriver] Creating session with MJSONWP desired capabilities: {“app”:"C:\Program Files (… [BaseDriver] Session created with session id: bbc83405-48e9-410f-b458-0fbe31ad455f [AndroidDriver] Getting Java version [AndroidDriver] Java version is: 10.0.1 [ADB] Checking whether adb is present [ADB] Found 1 ‘build-tools’ folders under ‘C:\Android\Sdk’ (newest first): [ADB] C:/Android/Sdk/build-tools/27.0.3 [ADB] Using adb.exe from C:\Android\Sdk\platform-tools\adb.exe [AndroidDriver] Retrieving device list [ADB] Trying to find a connected android device [ADB] Getting connected devices… [ADB] 1 device(s) connected [AndroidDriver] Using device: 6383a624 [ADB] Checking whether adb is present [ADB] Using adb.exe from C:\Android\Sdk\platform-tools\adb.exe [ADB] Setting device id to 6383a624 [BaseDriver] Using local app ‘C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk’ [AndroidDriver] Checking whether app is actually present [AndroidDriver] Starting Android session [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 wait-for-device’ [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell echo ping’ [AndroidDriver] Pushing settings apk to device… [ADB] Getting install status for io.appium.settings [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell pm list packages io.appium.settings’ [ADB] App is installed [ADB] Getting package info for ‘io.appium.settings’ [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell dumpsys package io.appium.settings’ [ADB] Checking whether aapt is present [ADB] Using aapt.exe from C:\Android\Sdk\build-tools\27.0.3\aapt.exe [ADB] The installed ‘io.appium.settings’ package does not require upgrade (‘2.3.0’ >= ‘2.3.0’) [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell ps’ [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell getprop ro.build.version.sdk’ [ADB] Current device property ‘ro.build.version.sdk’: 21 [ADB] Device API level: 21 [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell am start -W -n io.appium.settings/.Settings -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -f 0x10200000’ [ADB] Device API level: 21 [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell settings put secure mock_location 1’ [AndroidDriver] setDeviceLanguageCountry requires language or country. [AndroidDriver] Got language: ‘undefined’ and country: ‘undefined’ [Logcat] Starting logcat capture [AndroidDriver] Pushing unlock helper app to device… [ADB] Getting install status for io.appium.unlock [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell pm list packages io.appium.unlock’ [ADB] App is installed [ADB] Getting package info for ‘io.appium.unlock’ [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell dumpsys package io.appium.unlock’ [ADB] Checking whether aapt is present [ADB] Using aapt.exe from C:\Android\Sdk\build-tools\27.0.3\aapt.exe [ADB] The installed ‘io.appium.unlock’ package does not require upgrade (‘2.0.0’ >= ‘2.0.0’) [ADB] Getting device platform version [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell getprop ro.build.version.release’ [ADB] Current device property ‘ro.build.version.release’: 5.0.1 [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell wm size’ [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell getprop ro.product.model’ [ADB] Current device property ‘ro.product.model’: GT-I9506 [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell getprop ro.product.manufacturer’ [ADB] Current device property ‘ro.product.manufacturer’: samsung [AndroidDriver] Parsing package and activity from app manifest [ADB] Using the alternative activity name detection method because of: Could not find apkanalyzer.bat in C:\Android\Sdk\platform-tools\apkanalyzer.bat,C:\Android\Sdk\emulator\apkanalyzer.bat,C:\Android\Sdk\tools\apkanalyzer.bat,C:\Android\Sdk\tools\bin\apkanalyzer.bat,C:\Android\Sdk\build-tools\27.0.3\apkanalyzer.bat. Do you have the Android SDK installed at ‘C:\Android\Sdk’? [ADB] Checking whether aapt is present [ADB] Using aapt.exe from C:\Android\Sdk\build-tools\27.0.3\aapt.exe [ADB] Extracting package and launch activity from manifest [ADB] Package name: ‘io.appium.unlock’ [ADB] Main activity name: ‘io.appium.unlock.Unlock’ [AndroidDriver] Parsed package and activity are: io.appium.unlock/io.appium.unlock.Unlock [ADB] Getting install status for io.appium.unlock [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell pm list packages io.appium.unlock’ [ADB] App is installed [ADB] Getting install status for io.appium.unlock [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell pm list packages io.appium.unlock’ [ADB] App is installed [ADB] Getting package info for ‘io.appium.unlock’ [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell dumpsys package io.appium.unlock’ [ADB] Checking whether aapt is present [ADB] Using aapt.exe from C:\Android\Sdk\build-tools\27.0.3\aapt.exe [ADB] The installed ‘io.appium.unlock’ package does not require upgrade (‘2.0.0’ >= ‘2.0.0’) [AndroidDriver] Performing fast reset on ‘io.appium.unlock’ [ADB] Getting install status for io.appium.unlock [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell pm list packages io.appium.unlock’ [ADB] App is installed [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell am force-stop io.appium.unlock’ [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell pm clear io.appium.unlock’ [AndroidDriver] Performed fast reset on the installed ‘io.appium.unlock’ application (stop and clear) [ADB] Getting connected devices… [ADB] 1 device(s) connected [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 shell rm -rf /data/local/tmp/strings.json’ [AndroidDriver] Extracting strings from apk [AndroidDriver] C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk [AndroidDriver] undefined [AndroidDriver] C:\Users\fese\AppData\Local\Temp\io.appium.unlock [ADB] Extracting strings for language: default [ADB] Checking whether aapt is present [ADB] Using aapt.exe from C:\Android\Sdk\build-tools\27.0.3\aapt.exe [Logcat] Logcat terminated with code 0, signal null [ADB] Successfully extracted 1 strings from ‘C:\Program Files (x86)\Appium\resources\app\node_modules\appium-unlock\bin\unlock_apk-debug.apk’ resources for ‘(default)’ configuration [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 push C:\Users\fese\AppData\Local\Temp\io.appium.unlock\strings.json /data/local/tmp’ [ADB] Running ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 push C:\Users\fese\AppData\Local\Temp\io.appium.unlock\strings.json /data/local/tmp’ [AndroidDriver] Could not get strings, continuing anyway. Original error: Error executing adbExec. Original error: ‘Command ‘C:\Android\Sdk\platform-tools\adb.exe -P 5037 -s 6383a624 push C:\Users\fese\AppData\Local\Temp\io.appium.unlock\strings.json /data/local/tmp’ exited with code 1’; Stderr: ‘’; Code: ‘1’ [ADB] Getting connected devices… [ADB] 0 device(s) connected [AndroidDriver] Shutting down Android driver [AndroidDriver] Called deleteSession but bootstrap wasn’t active [Logcat] Stopping logcat capture [Logcat] Logcat already stopped [ADB] Getting connected devices… [ADB] 0 device(s) connected [BaseDriver] Event ‘newSessionStarted’ logged at 1526902874667 (13:41:14 GMT+0200 (Central European Daylight Time)) [W3C] Encountered internal error running command: TypeError: cmd.join is not a function [W3C] at ADB.callee$0$0$ (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-adb\lib\tools\system-calls.js:337:79) [W3C] at tryCatch (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-adb\node_modules\babel-runtime\regenerator\runtime.js:67:40) [W3C] at GeneratorFunctionPrototype.invoke [as _invoke] (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-adb\node_modules\babel-runtime\regenerator\runtime.js:315:22) [W3C] at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-adb\node_modules\babel-runtime\regenerator\runtime.js💯21) [W3C] at GeneratorFunctionPrototype.invoke (C:\Program Files (x86)\Appium\resources\app\node_modules\appium-adb\node_modules\babel-runtime\regenerator\runtime.js:136:37) [W3C] at [HTTP] <-- POST /wd/hub/session 500 12775 ms - 1376 [HTTP]
Issue Analytics
- State:
- Created 5 years ago
- Comments:5
Top GitHub Comments
The fix for the error message has been pushed to appium@beta
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.