Supun Abesekara
Supun Abesekara

Reputation: 736

React Native android adbExe does not exist

While i run react native android app in visual code i get this error. I need help to resolve this issue. Thanks.

FAILURE: Build failed with an exception.

What went wrong: A problem was found with the configuration of task ':app:installDebug'.

File 'C:\Users\Supun\AppData\Local\Android\Sdk\platform-tools\adb.exe' specified for property 'adbExe' does not exist.

Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

Get more help at https://help.gradle.org

BUILD FAILED in 4m 34s 26 actionable tasks: 26 executed Could not install the app on the device, read the error above for details. Make sure you have an Android emulator running or a device connected and have set up your Android development environment:

https://facebook.github.io/react-native/docs/getting-started.html
events.js:183
      throw er; // Unhandled 'error' event
      ^

Error: spawn cmd.exe ENOENT
    at _errnoException (util.js:1024:11)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:190:19)
    at onErrorNT (internal/child_process.js:372:16)
    at _combinedTickCallback (internal/process/next_tick.js:138:11)
    at process._tickCallback (internal/process/next_tick.js:180:9)

Upvotes: 6

Views: 1759

Answers (1)

nochkin
nochkin

Reputation: 710

I know this is an old topic, but I'll post it here in case if anyone is having the same issue.

For me, this usually happens when WSL is being used, while Android SDK is installed under Windows (there you have adb.exe instead of adb).

Making another copy of adb.exe binary as adb resolved the issue for me:

copy adb.exe adb

Upvotes: 7

Related Questions