npx react-native run-android: Task :app:installDebug FAILED
See original GitHub issueDescription:
I am trying to run react native app to my real android device. But got an error. Here is full scan of my stacktrace
> Task :app:installDebug FAILED
07:14:18 V/ddms: execute: running am get-config
07:14:18 V/ddms: execute 'am get-config' on '3357425441473098' : EOF hit. Read: -1
07:14:18 V/ddms: execute: returning
Installing APK 'app-debug.apk' on 'SM-G960U - 9' for app:debug
07:14:18 D/app-debug.apk: Uploading app-debug.apk onto device '3357425441473098'
07:14:18 D/Device: Uploading file onto device '3357425441473098'
07:14:18 D/ddms: Reading file permision of /home/user/react-native/AwesomeProject/android/app/build/outputs/apk/debug/app-debug.apk as: rw-r
w-r--
07:14:18 D/ddms: read: channel EOF
07:14:18 E/Device: Error during Sync: EOF
Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.5/userguide/command_line_interface.html#sec:command_line_warnings
27 actionable tasks: 27 executed
Unable to install /home/user/react-native/AwesomeProject/android/app/build/outputs/apk/debug/app-debug.apk
com.android.ddmlib.InstallException: EOF
* What went wrong:
Execution failed for task ':app:installDebug'.
> com.android.builder.testing.api.DeviceException: com.android.ddmlib.InstallException: EOF
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full i
nsights.
* Get more help at https://help.gradle.org
BUILD FAILED in 18s
error Failed to install the app. Make sure you have the Android development environment set up: https://facebook.github.io/react-native/docs
/getting-started.html#android-development-environment. Run CLI with --verbose flag for more details.
Error: Command failed: ./gradlew app:installDebug -PreactNativeDevServerPort=8081
Unable to install /home/user/react-native/AwesomeProject/android/app/build/outputs/apk/debug/app-debug.apk
com.android.ddmlib.InstallException: EOF
React Native version:
System: OS: Linux 4.19 Fedora 30 (Thirty) 30 (Thirty) CPU: (2) x64 Intel® Core™ i7-7700K CPU @ 4.20GHz Memory: 1.94 GB / 7.59 GB Shell: 5.7.1 - /usr/bin/zsh Binaries: Node: 10.16.3 - /usr/bin/node Yarn: 1.21.1 - /usr/bin/yarn npm: 6.9.0 - /usr/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman SDKs: Android SDK: API Levels: 28, 29 Build Tools: 28.0.3, 29.0.3 System Images: android-28 | Intel x86 Atom_64, android-28 | Google APIs Intel x86 Atom, android-28 | Google APIs Intel x86 Atom_64, android-29 | Intel x86 Atom_64, android-29 | Google APIs Intel x86 Atom, android-29 | Google APIs Intel x86 Atom_64 npmPackages: react: 16.9.0 => 16.9.0 react-native: 0.61.5 => 0.61.5
Steps To Reproduce
I checked my device before running
adb devices
List of devices attached
3357425441473098 device
creating a new project…
npx react-native AwesomeProject
I started with
npx react-native start
and in other console
npx react-native run-android
Expected Results
New app installed in my device.
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (1 by maintainers)
Top GitHub Comments
@freewebwithme looks like you will need to delete your old version of
app-debug.apk
inSM-G960U - 9
|3357425441473098
🎉If this isn’t working…
try this
adb kill-server
adb start-server
Hey guys! I have the same problem and cannot solve it. Could someone fix it? Any ideas?