Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

error: Logcat capture failed: spawn ENOENT - Appium

Tags:

appium

I am running android test using appium. But getting the error. See below the appium logs.Please help to resolve this error.Have searched and got the soln is,appium will not accept the space in android path. But there is no space here.


info: Welcome to Appium v1.3.5 (REV a124a15677e26b33db16e81c4b3b34d9c6b8cac9)
info: Appium REST http interface listener started on 0.0.0.0:4723
info: Console LogLevel: debug
info: --> POST /wd/hub/session {"desiredCapabilities":{"deviceName":"Android","platformName":"Android","browserName":"","platformVersion":"5.0.2","app":"../../../../NavAir.apk","app-package":"com.accenture.voyageextension","app-activity":"com.accenture.voyageextension.NavAir"}}
info: Client User-Agent string: Ruby
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. : app-package, app-activity
info: [debug] No appActivity desired capability or server param. Parsing from apk.
info: [debug] No appPackage desired capability or server param. Parsing from apk.
info: [debug] Using local app from desired caps: /Users/rajesh.madaswamy/NavAir.apk
info: [debug] Creating new appium session 3bb611f1-469f-4ebe-bed9-26a86f883812
info: Starting android appium
info: [debug] Getting Java version
info: Java version is: 1.7.0_71
info: [debug] Checking whether adb is present
warn: The ANDROID_HOME environment variable is not set to the Android SDK root directory path. ANDROID_HOME is required for compatibility with SDK 23+. Checking along PATH for adb.
info: [debug] executing cmd: which adb
info: [debug] Using adb from /Applications/AndroidSdk/sdk/platform-tools/adb

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: "/Applications/AndroidSdk/sdk/platform-tools/adb" devices
info: [debug] 1 device(s) connected
info: Found device 4d0061af4fb92185
info: [debug] Setting device id to 4d0061af4fb92185
info: [debug] Waiting for device to be ready and to respond to shell commands (timeout = 5)
info: [debug] executing cmd: "/Applications/AndroidSdk/sdk/platform-tools/adb" -s 4d0061af4fb92185 wait-for-device
info: [debug] executing cmd: "/Applications/AndroidSdk/sdk/platform-tools/adb" -s 4d0061af4fb92185 shell "echo 'ready'"
info: [debug] Starting logcat capture
error: Logcat capture failed: spawn "/Applications/AndroidSdk/sdk/platform-tools/adb" ENOENT
info: [debug] Stopping logcat capture
info: <-- POST /wd/hub/session - - ms - - 
undefined
like image 776
rajesh madaswamy Avatar asked Feb 17 '15 07:02

rajesh madaswamy


1 Answers

Error shows your android_home is not set. Use this:

export ANDROID_HOME=/Users/kumarg/Documents/Android/sdk/platform-tools

Hope this will fix the issue

like image 116
Gaurav Avatar answered Nov 08 '22 16:11

Gaurav