Closed tgolen closed 4 years ago
I ran through the instructions for seeing up android environment here: https://reactnative.dev/docs/environment-setup#docsNav
It got further, but I'm still hitting an error.
Tims-MacBook-Pro:ReactNativeChat tim$ npm run android
> react-native-chat@1.0.1-2 android /Users/tim/code/Expensidev/ReactNativeChat
> react-native run-android
info Running jetifier to migrate libraries to AndroidX. You can disable it using "--no-jetifier" flag.
Jetifier found 1011 file(s) to forward-jetify. Using 8 workers...
info Starting JS server...
info Launching emulator...
error Failed to launch emulator. Reason: Emulator exited before boot..
warn Please launch an emulator manually or connect a device. Otherwise app may fail to launch.
info Installing the app...
> Configure project :app
Reading env from: .env
> Task :app:generateDebugBuildConfig
Reading env from: .env
> Task :react-native-community_netinfo:compileDebugJavaWithJavac
> Task :react-native-community_async-storage:compileDebugJavaWithJavac
> Task :app:compileDebugJavaWithJavac
> Task :app:installDebug FAILED
Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.2/userguide/command_line_interface.html#sec:command_line_warnings
103 actionable tasks: 103 executed
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: /Users/tim/code/Expensidev/ReactNativeChat/node_modules/@react-native-community/async-storage/android/src/main/java/com/reactnativecommunity/asyncstorage/AsyncStorageModule.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: /Users/tim/code/Expensidev/ReactNativeChat/android/app/src/debug/java/com/reactnativechat/ReactNativeFlipper.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:installDebug'.
> com.android.builder.testing.api.DeviceException: No connected devices!
* 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 insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 38s
error Failed to install the app. Make sure you have an Android emulator running or a device connected. Run CLI with --verbose flag for more details.
Error: Command failed: ./gradlew app:installDebug -PreactNativeDevServerPort=8081
Note: Some input files use or override a deprecated API.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! react-native-chat@1.0.1-2 android: `react-native run-android`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the react-native-chat@1.0.1-2 android script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/tim/.npm/_logs/2020-08-15T15_50_56_768Z-debug.log
Tims-MacBook-Pro:ReactNativeChat tim$
Demoting this to LOW because it doesn't affect the first-time user experience
I solved the final error by having a running emulator 👍 Just making a record of this for others.
Full logs:
cc @AndrewGable I'm going to be digging into this to get it working today.