org.openqa.selenium.WebDriverException: An unknown server-side error occurred while processing the command

Hi,
I am new to appium while running the scripts through eclipse I am getting the error as above, my code is below

package Automation;

import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.concurrent.TimeUnit;

import org.openqa.selenium.By;

import org.openqa.selenium.remote.CapabilityType;
import org.openqa.selenium.remote.DesiredCapabilities;
import org.testng.annotations.AfterTest;
import org.testng.annotations.BeforeTest;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;

import io.appium.java_client.android.AndroidDriver;
import io.appium.java_client.remote.MobileCapabilityType;

public class ServiceSathi {
AndroidDriver driver;
@BeforeTest
public void Configration() throws MalformedURLException{
String apkpath=“D:\SDK\apps\com.servicesathi.apk”;
File app=new File(apkpath);
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability(CapabilityType.BROWSER_NAME, “Android”);
capabilities.setCapability(“deviceName”, “850cceea9904”);
capabilities.setCapability(CapabilityType.VERSION, “6.0.1”);
capabilities.setCapability(“platformName”, “Android”);
capabilities.setCapability(MobileCapabilityType.APP, apkpath);
driver = new AndroidDriver(new URL(“http://127.0.0.1:4723/wd/hub”), capabilities);
driver.manage().timeouts().implicitlyWait(15, TimeUnit.SECONDS);
}
@Test
public void Sum() {
driver.findElement(By.className(“android.view.View”)).sendKeys(“9703843454”);
}
@AfterTest
public void End() {
driver.quit();
}
}

@chittiboina.premkuma Please put capabilities app package and app activity for android app

Its opening the application, but the error is displaying

What is the error cn share appium logs too. @chittiboina.premkuma

Appium logs : > Launching Appium server with command: C:\Program Files\Appium\node.exe lib\server\main.js --address 127.0.0.1 --port 4723 --app D:\SDK\apps\com.servicesathi.apk --app-pkg com.servicesathi --platform-name Android --platform-version 23 --automation-name Appium --log-no-color

info: Welcome to Appium v1.4.16 (REV ae6877eff263066b26328d457bd285c0cc62430d)
info: Appium REST http interface listener started on 127.0.0.1:4723
info: [debug] Non-default server args: {“app”:“D:\SDK\apps\com.servicesathi.apk”,“address”:“127.0.0.1”,“logNoColors”:true,“androidPackage”:“com.servicesathi”,“platformName”:“Android”,“platformVersion”:“23”,“automationName”:“Appium”}
info: Console LogLevel: debug
info: → POST /wd/hub/session {“desiredCapabilities”:{“app”:“D:\SDK\apps\com.servicesathi.apk”,“browserName”:“Android”,“platformName”:“Android”,“deviceName”:“850cceea9904”,“version”:“6.0.1”}}
info: Client User-Agent string: Apache-HttpClient/4.5.1 (Java/1.8.0_131)
info: [debug] The following desired capabilities were provided, but not recognized by appium. They will be passed on to any other services running on this server. : version
info: [debug] No appActivity desired capability or server param. Parsing from apk.
info: [debug] Using local app from desired caps: D:\SDK\apps\com.servicesathi.apk
info: [debug] Creating new appium session 7dfdd788-142b-4b46-9589-d8b21b9e886a
info: Starting android appium
info: [debug] Getting Java version
info: Java version is: 1.8.0_131
info: [debug] Checking whether adb is present
info: [debug] Using adb from D:\SDK\platform-tools\adb.exe
info: [debug] Parsing package and activity from app manifest
info: [debug] Checking whether aapt is present
info: [debug] Using aapt from D:\SDK\build-tools\26.0.0\aapt.exe
info: [debug] Extracting package and launch activity from manifest.
info: [debug] executing cmd: D:\SDK\build-tools\26.0.0\aapt.exe dump badging D:\SDK\apps\com.servicesathi.apk
info: [debug] badging package: com.servicesathi
info: [debug] badging act: com.servicesathi.MainActivity
info: [debug] Parsed package and activity are: com.servicesathi/com.servicesathi.MainActivity
info: [debug] Using fast reset? true
info: [debug] Preparing device for session
info: [debug] Checking whether app is actually present
info: Retrieving device
info: [debug] Trying to find a connected android device
info: [debug] Getting connected devices…
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe devices
info: [debug] 1 device(s) connected
info: Found device 850cceea9904
info: [debug] Setting device id to 850cceea9904
info: [debug] Waiting for device to be ready and to respond to shell commands (timeout = 5)
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 wait-for-device
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “echo ‘ready’”
info: [debug] Starting logcat capture
info: [debug] Getting device API level
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “getprop ro.build.version.sdk”
info: [debug] Device is at API Level 23
info: Device API level is: 23
info: [debug] Extracting strings for language: default
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “getprop persist.sys.language”
info: [debug] Current device persist.sys.language:
info: [debug] java -jar “C:\Program Files\Appium\node_modules\appium\node_modules\appium-adb\jars\appium_apk_tools.jar” “stringsFromApk” “D:\SDK\apps\com.servicesathi.apk” “C:\Users\Lenovo\AppData\Local\Temp\com.servicesathi”
info: [debug] Reading strings from converted strings.json
info: [debug] Setting language to default
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 push “C:\Users\Lenovo\AppData\Local\Temp\com.servicesathi\strings.json” /data/local/tmp
info: [debug] Checking whether aapt is present
info: [debug] Using aapt from D:\SDK\build-tools\26.0.0\aapt.exe
info: [debug] Retrieving process from manifest.
info: [debug] executing cmd: D:\SDK\build-tools\26.0.0\aapt.exe dump xmltree D:\SDK\apps\com.servicesathi.apk AndroidManifest.xml
info: [debug] Set app process to: com.servicesathi
info: [debug] Not uninstalling app since server not started with --full-reset
info: [debug] Checking app cert for D:\SDK\apps\com.servicesathi.apk.
info: [debug] executing cmd: java -jar “C:\Program Files\Appium\node_modules\appium\node_modules\appium-adb\jars\verify.jar” D:\SDK\apps\com.servicesathi.apk
info: [debug] App already signed.
info: [debug] Zip-aligning D:\SDK\apps\com.servicesathi.apk
info: [debug] Checking whether zipalign is present
info: [debug] Using zipalign from D:\SDK\build-tools\26.0.0\zipalign.exe
info: [debug] Zip-aligning apk.
info: [debug] executing cmd: D:\SDK\build-tools\26.0.0\zipalign.exe -f 4 D:\SDK\apps\com.servicesathi.apk C:\Users\Lenovo\AppData\Local\Temp\117612-4332-168rgff\appium.tmp
info: [debug] MD5 for app is 0da764fcfcc041967d16edbea3033ed4
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “ls /data/local/tmp/0da764fcfcc041967d16edbea3033ed4.apk”
info: [debug] Getting install status for com.servicesathi
info: [debug] Getting device API level
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “getprop ro.build.version.sdk”
info: [debug] Device is at API Level 23
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “pm list packages -3 com.servicesathi”
info: [debug] App is installed
info: App is already installed, resetting app
info: [debug] Running fast reset (stop and clear)
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “am force-stop com.servicesathi”
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “pm clear com.servicesathi”
info: [debug] Forwarding system:4724 to device:4724
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 forward tcp:4724 tcp:4724
info: [debug] Pushing appium bootstrap to device…
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 push “C:\Program Files\Appium\node_modules\appium\build\android_bootstrap\AppiumBootstrap.jar” /data/local/tmp/
info: [debug] Pushing settings apk to device…
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 install “C:\Program Files\Appium\node_modules\appium\build\settings_apk\settings_apk-debug.apk”
info: [debug] Pushing unlock helper app to device…
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 install “C:\Program Files\Appium\node_modules\appium\build\unlock_apk\unlock_apk-debug.apk”
info: Starting App
info: [debug] Attempting to kill all ‘uiautomator’ processes
info: [debug] Getting all processes with ‘uiautomator’
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “ps ‘uiautomator’”
info: [debug] No matching processes found
info: [debug] Running bootstrap
info: [debug] spawning: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell uiautomator runtest AppiumBootstrap.jar -c io.appium.android.bootstrap.Bootstrap -e pkg com.servicesathi -e disableAndroidWatchers false
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: numtests=1
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: stream=
info: [debug] [UIAUTOMATOR STDOUT] io.appium.android.bootstrap.Bootstrap:
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: id=UiAutomatorTestRunner
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: test=testRunServer
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: class=io.appium.android.bootstrap.Bootstrap
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: current=1
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS_CODE: 1
info: [debug] [BOOTSTRAP] [debug] Socket opened on port 4724
info: [debug] [BOOTSTRAP] [debug] Appium Socket Server Ready
info: [debug] [BOOTSTRAP] [debug] Loading json…
info: [debug] [BOOTSTRAP] [debug] json loading complete.
info: [debug] [BOOTSTRAP] [debug] Registered crash watchers.
info: [debug] Waking up device if it’s not alive
info: [debug] Pushing command to appium work queue: [“wake”,{}]
info: [debug] [BOOTSTRAP] [debug] Client connected
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“wake”,“params”:{}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: wake
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:0,“value”:true}
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “dumpsys window”
info: [debug] Screen already unlocked, continuing.
info: [debug] Pushing command to appium work queue: [“getDataDir”,{}]
info: [debug] dataDir set to: /data/local/tmp
info: [debug] Pushing command to appium work queue: [“compressedLayoutHierarchy”,{“compressLayout”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“getDataDir”,“params”:{}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: getDataDir
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:0,“value”:“/data/local/tmp”}
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“compressedLayoutHierarchy”,“params”:{“compressLayout”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: compressedLayoutHierarchy
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:0,“value”:false}
info: [debug] Getting device API level
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “getprop ro.build.version.sdk”
info: [debug] Device is at API Level 23
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “am start -S -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -f 0x10200000 -n com.servicesathi/com.servicesathi.MainActivity”
info: [debug] Waiting for pkg “com.servicesathi” and activity “com.servicesathi.MainActivity” to be focused
info: [debug] Getting focused package and activity
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “dumpsys window windows”
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “getprop ro.build.version.release”
info: [debug] Device is at release version 6.0.1
info: [debug] Device launched! Ready for commands
info: [debug] Setting command timeout to the default of 60 secs
info: [debug] Appium session started with sessionId 7dfdd788-142b-4b46-9589-d8b21b9e886a
info: ← POST /wd/hub/session 303 15513.419 ms - 74
info: → GET /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a {}
info: [debug] Responding to client with success: {“status”:0,“value”:{“platform”:“LINUX”,“browserName”:“Android”,“platformVersion”:“6.0.1”,“webStorageEnabled”:false,“takesScreenshot”:true,“javascriptEnabled”:true,“databaseEnabled”:false,“networkConnectionEnabled”:true,“locationContextEnabled”:false,“warnings”:{},“desired”:{“app”:“D:\SDK\apps\com.servicesathi.apk”,“browserName”:“Android”,“platformName”:“Android”,“deviceName”:“850cceea9904”,“version”:“6.0.1”},“app”:“D:\SDK\apps\com.servicesathi.apk”,“platformName”:“Android”,“deviceName”:“850cceea9904”,“version”:“6.0.1”},“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: ← GET /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a 200 4.748 ms - 583 {“status”:0,“value”:{“platform”:“LINUX”,“browserName”:“Android”,“platformVersion”:“6.0.1”,“webStorageEnabled”:false,“takesScreenshot”:true,“javascriptEnabled”:true,“databaseEnabled”:false,“networkConnectionEnabled”:true,“locationContextEnabled”:false,“warnings”:{},“desired”:{“app”:“D:\SDK\apps\com.servicesathi.apk”,“browserName”:“Android”,“platformName”:“Android”,“deviceName”:“850cceea9904”,“version”:“6.0.1”},“app”:“D:\SDK\apps\com.servicesathi.apk”,“platformName”:“Android”,“deviceName”:“850cceea9904”,“version”:“6.0.1”},“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: → POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/timeouts {“type”:“implicit”,“ms”:15000}
info: [debug] Set Android implicit wait to 15000ms
info: [debug] Responding to client with success: {“status”:0,“value”:null,“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: ← POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/timeouts 200 3.985 ms - 76 {“status”:0,“value”:null,“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: → POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element {“using”:“xpath”,“value”:“//android.view.View[@content-desc=‘Phone Number’]”}
info: [debug] Waiting up to 15000ms for condition
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 201ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 732ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 1263ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 1796ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 2323ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 2856ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 3386ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 3918ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 4446ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] Waited for 4977ms so far
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 5509ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 6039ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 6571ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 7102ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 7633ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:7,“value”:“Could not find an element using supplied strategy. “}
info: [debug] Waited for 8174ms so far
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:”//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Using: UiSelector[CLASS=android.view.View, INSTANCE=11]
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:0,“value”:{“ELEMENT”:“1”}}
info: [debug] Responding to client with success: {“status”:0,“value”:{“ELEMENT”:“1”},“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: ← POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element 200 9018.120 ms - 87 {“status”:0,“value”:{“ELEMENT”:“1”},“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: → POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element/1/click {“id”:“1”}
info: [debug] Pushing command to appium work queue: [“element:click”,{“elementId”:“1”}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“element:click”,“params”:{“elementId”:“1”}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: click
info: [debug] Responding to client with success: {“status”:0,“value”:true,“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: ← POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element/1/click 200 475.558 ms - 76 {“status”:0,“value”:true,“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: → POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element {“using”:“xpath”,“value”:“//android.view.View[@content-desc=‘Phone Number’]”}
info: [debug] Waiting up to 15000ms for condition
info: [debug] Pushing command to appium work queue: [“find”,{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}]
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:0,“value”:true}
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“find”,“params”:{“strategy”:“xpath”,“selector”:“//android.view.View[@content-desc=‘Phone Number’]”,“context”:“”,“multiple”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: find
info: [debug] [BOOTSTRAP] [debug] Finding //android.view.View[@content-desc=‘Phone Number’] using XPATH with the contextId: multiple: false
info: [debug] [BOOTSTRAP] [debug] Using: UiSelector[CLASS=android.view.View, INSTANCE=11]
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:0,“value”:{“ELEMENT”:“2”}}
info: [debug] Responding to client with success: {“status”:0,“value”:{“ELEMENT”:“2”},“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: ← POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element 200 132.039 ms - 87 {“status”:0,“value”:{“ELEMENT”:“2”},“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: → POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element/2/value {“id”:“2”,“value”:[“9703843454”]}
info: [debug] Pushing command to appium work queue: [“element:setText”,{“elementId”:“2”,“text”:“9703843454”,“replace”:false}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“element:setText”,“params”:{“elementId”:“2”,“text”:“9703843454”,“replace”:false}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: setText
info: [debug] [BOOTSTRAP] [debug] Using element passed in.
info: [debug] [BOOTSTRAP] [debug] Attempting to clear using UiObject.clearText().
info: [debug] [BOOTSTRAP] [debug] Sending plain text to element: 9703843454
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:13,“value”:“Unknown error”}
info: [debug] Responding to client with error: {“status”:13,“value”:{“message”:“An unknown server-side error occurred while processing the command.”,“origValue”:“Unknown error”},“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: ← POST /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a/element/2/value 500 200.523 ms - 182
info: → DELETE /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a {}
info: Shutting down appium session
info: [debug] Pressing the HOME button
info: [debug] executing cmd: D:\SDK\platform-tools\adb.exe -s 850cceea9904 shell “input keyevent 3”
info: [debug] Stopping logcat capture
info: [debug] Logcat terminated with code null, signal SIGTERM
info: [debug] Sent shutdown command, waiting for UiAutomator to stop…
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“shutdown”}
info: [debug] [BOOTSTRAP] [debug] Got command of type SHUTDOWN
info: [debug] [BOOTSTRAP] [debug] Returning result: {“status”:0,“value”:“OK, shutting down”}
info: [debug] [BOOTSTRAP] [debug] Closed client connection
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: numtests=1
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: stream=.
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: id=UiAutomatorTestRunner
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: test=testRunServer
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: class=io.appium.android.bootstrap.Bootstrap
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: current=1
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS_CODE: 0
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: stream=
info: [debug] [UIAUTOMATOR STDOUT] Test results for WatcherResultPrinter=.
info: [debug] [UIAUTOMATOR STDOUT] Time: 12.098
info: [debug] [UIAUTOMATOR STDOUT] OK (1 test)
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS_CODE: -1
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_RESULT: shortMsg=java.lang.SecurityException
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_RESULT: longMsg=Permission Denial: getIntentSender() from pid=30821, uid=2000, (need uid=1000) is not allowed to send as package android
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_CODE: 0
info: [debug] UiAutomator shut down normally
info: [debug] Cleaning up android objects
info: [debug] Cleaning up appium session
info: [debug] Responding to client with success: {“status”:0,“value”:null,“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}
info: ← DELETE /wd/hub/session/7dfdd788-142b-4b46-9589-d8b21b9e886a 200 633.870 ms - 76 {“status”:0,“value”:null,“sessionId”:“7dfdd788-142b-4b46-9589-d8b21b9e886a”}

Eclipse error :
FAILED: Sum
org.openqa.selenium.WebDriverException: An unknown server-side error occurred while processing the command. (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 211 milliseconds
Build info: version: ‘2.53.1’, revision: ‘a36b8b1’, time: ‘2016-06-30 17:37:03’
System info: host: ‘LP-Harichan24’, ip: ‘192.168.0.101’, os.name: ‘Windows 7’, os.arch: ‘amd64’, os.version: ‘6.1’, java.version: ‘1.8.0_131’
Driver info: io.appium.java_client.android.AndroidDriver
Capabilities [{app=D:\SDK\apps\com.servicesathi.apk, networkConnectionEnabled=true, warnings={}, databaseEnabled=false, deviceName=850cceea9904, version=6.0.1, platform=LINUX, desired={app=D:\SDK\apps\com.servicesathi.apk, browserName=Android, platformName=Android, deviceName=850cceea9904, version=6.0.1}, platformVersion=6.0.1, webStorageEnabled=false, locationContextEnabled=false, browserName=Android, takesScreenshot=true, javascriptEnabled=true, platformName=Android}]
Session ID: 7dfdd788-142b-4b46-9589-d8b21b9e886a
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:206)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:158)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:678)
at io.appium.java_client.AppiumDriver.execute(AppiumDriver.java:180)
at org.openqa.selenium.remote.RemoteWebElement.execute(RemoteWebElement.java:327)
at org.openqa.selenium.remote.RemoteWebElement.sendKeys(RemoteWebElement.java:122)
at Automation.ServiceSathi.Sum(ServiceSathi.java:40)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:85)
at org.testng.internal.Invoker.invokeMethod(Invoker.java:639)
at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:816)
at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1124)
at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:125)
at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:108)
at org.testng.TestRunner.privateRun(TestRunner.java:774)
at org.testng.TestRunner.run(TestRunner.java:624)
at org.testng.SuiteRunner.runTest(SuiteRunner.java:359)
at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:354)
at org.testng.SuiteRunner.privateRun(SuiteRunner.java:312)
at org.testng.SuiteRunner.run(SuiteRunner.java:261)
at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
at org.testng.TestNG.runSuitesSequentially(TestNG.java:1215)
at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
at org.testng.TestNG.run(TestNG.java:1048)
at org.testng.remote.AbstractRemoteTestNG.run(AbstractRemoteTestNG.java:132)
at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:230)
at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:76)

===============================================
Default test
Tests run: 1, Failures: 1, Skips: 0

Your application is opened but further command is not executed right ?.

Ok

Do one thing first make sure your versions are upgraded or not. May be it will come from versions compatibility. Then you should update your android sdk pakages.

Otherwise can you try to execute android lower version device it will execute properly means the problem is only happened for higher version…

Please use some ‘text’ property of the text field or if some other property
is available like content desc. Because classname gives issues .

Thank you sir,
But the problem is I am using Ionic framework application that to I installed from google play store. For that application can I inspect the elements using DDMS or UI automator viewer? Please give me some suggestions how to Inspect the elements in hybrid app

I used content-desc but it is giving same error, and let me know which tool is used to inspect the elements in Ionic application in Appium

Yes u can launch some other application for which u have apk then press
home button after launching and open it iconic application and try to
inspect it

Thank you sir,
But which tool is used to inspect the Ionic application elements

What iconic application ??

not “Iconic” sir, Its an android application with Ionic frameworks

You can watch this playlist : https://www.youtube.com/playlist?list=PLXbcghgSZDroz9nez1IrbL2hnMVJ0ba1W