0

The Android Debug Bridge (ADB) error below is given when running application on Eclipse.

How can I fix this?

Checking if an update is available
Launching Appium server with command: C:\Program Files (x86)\Appium\node.exe lib\server\main.js --address 127.0.0.1 --port 4723 --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: {"address":"127.0.0.1","logNoColors":true,"platformName":"Android","platformVersion":"23","automationName":"Appium"}
info: Console LogLevel: debug
Update not available
info: --> POST /wd/hub/session {"desiredCapabilities":{"appPackage":"com.android.calculator2","appActivity":"com.android.calculator2.Calculator","browserName":"Android","platformName":"Android","deviceName":"Galaxy S6","version":"6.0.1"}}
info: Client User-Agent string: undefined
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] Didn't get app but did get Android package, will attempt to launch it on the device
info: [debug] Creating new appium session 3515ed17-27c1-4a5e-bb48-db47b4b19235
info: Starting android appium
info: [debug] Getting Java version
info: Java version is: 1.8.0_111
info: [debug] Checking whether adb is present

error: Unhandled error: Error: ENOENT, no such file or directory 'C:\Users\Laksitha\AppData\Local\Android\sdk\tools;C:\Users\Laksitha\AppData\Local\Android\sdk\platform-tools\build-tools'

at Error (native)
at Object.fs.readdirSync (fs.js:761:18)
at exports.getDirectories (C:\Program Files (x86)\Appium\node_modules\appium\node_modules\appium-adb\lib\helpers.js:100:18)
at [object Object].ADB.checkSdkBinaryPresent (C:\Program Files (x86)\Appium\node_modules\appium\node_modules\appium-adb\lib\adb.js:97:25)
at [object Object].ADB.checkAdbPresent (C:\Program Files (x86)\Appium\node_modules\appium\node_modules\appium-adb\lib\adb.js:134:8)
at Function.ADB.createADB (C:\Program Files (x86)\Appium\node_modules\appium\node_modules\appium-adb\lib\adb.js:73:7)
at [object Object].androidCommon.initAdb (C:\Program Files (x86)\Appium\node_modules\appium\lib\devices\android\android-common.js:1083:9)
at C:\Program Files (x86)\Appium\node_modules\appium\node_modules\async\lib\async.js:607:21
at C:\Program Files (x86)\Appium\node_modules\appium\node_modules\async\lib\async.js:246:17
at iterate (C:\Program Files (x86)\Appium\node_modules\appium\node_modules\async\lib\async.js:146:13)
at C:\Program Files (x86)\Appium\node_modules\appium\node_modules\async\lib\async.js:157:25
at C:\Program Files (x86)\Appium\node_modules\appium\node_modules\async\lib\async.js:248:21
at C:\Program Files (x86)\Appium\node_modules\appium\node_modules\async\lib\async.js:612:34
at [object Object].<anonymous> (C:\Program Files (x86)\Appium\node_modules\appium\lib\devices\android\android-common.js:1077:12)
at [object Object].<anonymous> (C:\Program Files (x86)\Appium\node_modules\appium\lib\devices\android\android-common.js:1064:12)
at ChildProcess.exithandler (child_process.js:742:7)
at ChildProcess.emit (events.js:110:17)
at maybeClose (child_process.js:1016:16)
at Socket.<anonymous> (child_process.js:1184:11)
at Socket.emit (events.js:107:17)
at Pipe.close (net.js:484:11) context: [POST /wd/hub/session {"desiredCapabilities":{"appPackage":"com.android.calculator2","appActivity":"com.android.calculator2.Calculator","browserName":"Android","platformName":"Android","deviceName":"Galaxy S6","version":"6]
2
  • Looks like you know what the problem is, you highlighted it. Did you check those files exist ? no such file or directory 'C:\Users\Laksitha\AppData\Local\Android\sdk\tools;C:\Users\Laksitha\AppData\Local\Android\sdk\platform-tools\build-tools
    – Rsf
    Commented Nov 18, 2016 at 8:59
  • YES those files are exist and User variables looks like that ---> ANDROID_HOME C:\Users\Laksitha\AppData\Local\Android\sdk\tools;C:\Users\Laksitha\AppData\Local\Android\sdk\platform-tools
    – lak
    Commented Nov 18, 2016 at 9:02

1 Answer 1

2

Your environment variable is configured wrongly. Set the ANDROID_HOME environment variable to

C:\Users\Laksitha\AppData\Local\Android\android-sdk

instead of

C:\Users\Laksitha\AppData\Local\Android\sdk\tools;C:\Users\L‌​aksitha\AppData\Loca‌​l\Android\sdk\platfo‌​rm-tools
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.