React-native: RN 0.61.2 bug Android run Unable to determine the current character

Created on 21 Oct 2019  路  5Comments  路  Source: facebook/react-native

React Native version: 0.61.2
Node: 8.11.3 - C:\Program Files\nodejs\node.EXE
Yarn: 1.15.2 - C:\Users\sergio.araujo\AppData\Roaming\npm\yarn.CMD
npm: 5.6.0 - C:\Program Files\nodejs\npm.CMD
SDKs:
Android SDK:
API Levels: 23, 25, 26, 27, 28, 29
Build Tools: 27.0.3, 28.0.0, 28.0.1, 28.0.2, 28.0.3
System Images: android-25 | Intel x86 Atom_64, android-25 | Google Play Intel x86 Atom, android-26 | Google APIs Intel x86 Atom, android-27 | Intel x86 Atom_64, android-27 | Google APIs Intel x86 Atom
IDEs:
Android Studio: Version 3.5.0.0 AI-191.8026.42.35.5900203
npmPackages:
react: 16.9.0 => 16.9.0
react-native: 0.61.2 => 0.61.2

Steps To Reproduce

  1. react-native init AwesomeProject && npx react-native init AwesomeProject
  2. react-native run-android && react-native start... run-android

Describe what you expected to happen:
When trying to run the application 0.60.x or 0.61.x returns the error mentioned below. I've tried to install / run without global cli and change cli's 'def compile' settings

Snack, code example, screenshot, or link to a repository:

  • Where:
    Script 'C:\Users\sergio.araujo\Desktop\rn\AwesomeProject\node_modules\@react-native-community\cli-platform-android\native_modules.gradle' line: 182

  • What went wrong:
    A problem occurred evaluating script.

    Unable to determine the current character, it is not a string, number, array, or object

    The current character read is 'C' with an int value of 67
    Unable to determine the current character, it is not a string, number, array, or object
    line number 1
    index number 0

alt text

Bug Android

Most helpful comment

Just an update on this - the solution for me on app center was this:
https://github.com/microsoft/appcenter/issues/1285

basically do a
yarn add @react-native-community/cli-platform-android

All 5 comments

up

Seeing this same issue on azure app center on build since 0.6.1 - still happens on 0.6.3

Starting a Gradle Daemon (subsequent builds will be faster)
Gradle 5.5

FAILURE: Build failed with an exception.

* Where:
Script '/Users/runner/runners/2.160.0/work/1/s/AppName/node_modules/@react-native-community/cli-platform-android/native_modules.gradle' line: 182

* What went wrong:
A problem occurred evaluating script.
> Unable to determine the current character, it is not a string, number, array, or object

  The current character read is 'i' with an int value of 105
  Unable to determine the current character, it is not a string, number, array, or object
  line number 1
  index number 0
  info Run "react-native --help" to see a list of all available commands.

Just an update on this - the solution for me on app center was this:
https://github.com/microsoft/appcenter/issues/1285

basically do a
yarn add @react-native-community/cli-platform-android

Just an update on this - the solution for me on app center was this:
microsoft/appcenter#1285

basically do a
yarn add @react-native-community/cli-platform-android

anw It's worked for me! many thanks,

basically do a
yarn add @react-native-community/cli-platform-android

Works! Thnx!!!

Was this page helpful?
0 / 5 - 0 ratings