Skip to content

AppCenter error when building Android ReactNative #1

@jkoutavas

Description

@jkoutavas

When generating the most basic React Native app possible (npx react-native init AwesomeProject) we get this error when building it for Android on AppCenter:

##[section]Starting: Gradle Task
==============================================================================
Task         : Gradle
Description  : Build using a Gradle wrapper script
Version      : 1.128.0
Author       : Microsoft Corporation
Help         : [More Information](https://go.microsoft.com/fwlink/?LinkID=613720)
==============================================================================
SYSTEMVSSCONNECTION exists true
[command]/Users/runner/runners/2.160.1/work/1/s/AwesomeProject/android/gradlew -p AwesomeProject/android clean :app:assembleRelease
Starting a Gradle Daemon, 1 incompatible and 1 stopped Daemons could not be reused, use --status for details
Gradle 5.5

FAILURE: Build failed with an exception.

* Where:
Settings file '/Users/runner/runners/2.160.1/work/1/s/AwesomeProject/android/settings.gradle' line: 2

* What went wrong:
A problem occurred evaluating settings 'AwesomeProject'.
> Could not read script '/Users/runner/runners/2.160.1/work/1/s/AwesomeProject/node_modules/@react-native-community/cli-platform-android/native_modules.gradle' as it 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

BUILD FAILED in 7s
Error: /Users/runner/runners/2.160.1/work/1/s/AwesomeProject/android/gradlew failed with return code: 1
    at ChildProcess.<anonymous> (/Users/runner/runners/2.160.1/work/_tasks/Gradle_8d8eebd8-2b94-4c97-85af-839254cc6da4/1.128.0/node_modules/vsts-task-lib/toolrunner.js:569:30)
    at emitTwo (events.js:106:13)
    at ChildProcess.emit (events.js:191:7)
    at maybeClose (internal/child_process.js:886:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
##[error]Error: /Users/runner/runners/2.160.1/work/1/s/AwesomeProject/android/gradlew failed with return code: 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions