Skip to content

Android version fails to build in this projectΒ #460

Description

@brianzoller

I was able to build and run this sample project on the iOS simulator, but attempting to build the project for Android fails. Checking out the project and running according to the README results in this error. Note that the gradle plugin has moved from node_modules/react-native-gradle-plugin to node_modules/@react-native/gradle-plugin in some version prior to React Native 0.73.5.

info Opening app on Android...
info A dev server is already running for this project on port 8081.
info Installing the app...

info πŸ’‘ Tip: Make sure that you have set up your development environment correctly, by running npx react-native doctor. To read more about doctor command visit: https://github.com/react-native-community/cli/blob/main/packages/cli-doctor/README.md#doctor 


FAILURE: Build failed with an exception.

* What went wrong:
Included build '/Users/bzoller/src/github/okta-react-native-sample/node_modules/react-native-gradle-plugin' does not exist.

* 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

I have React Native configured correctly and I can run Android builds for other projects. Here is the output from npx react-native doctor command:

Common
 βœ“ Node.js - Required to execute JavaScript code
 βœ“ yarn - Required to install NPM dependencies
 βœ“ npm - Required to install NPM dependencies
 βœ“ Watchman - Used for watching changes in the filesystem when in development mode
 βœ“ Metro - Required for bundling the JavaScript code

Android
 βœ“ Adb - Required to verify if the android device is attached correctly
 βœ“ JDK - Required to compile Java code
 βœ“ Android Studio - Required for building and installing your app on Android
 βœ“ ANDROID_HOME - Environment variable that points to your Android SDK installation
 βœ“ Gradlew - Build tool required for Android builds
 βœ“ Android SDK - Required for building and installing your app on Android

iOS
 βœ“ Xcode - Required for building and installing your app on iOS
 βœ“ Ruby
 βœ“ CocoaPods - Required for installing iOS dependencies
 βœ“ ios-deploy - Required for installing your app on a physical device with the CLI
 βœ“ .xcode.env - File to customize Xcode environment

Errors:   0
Warnings: 0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions