Skip to main content

All Questions

Filter by
Sorted by
Tagged with
111 votes
14 answers
215k views

error: package com.android.annotations does not exist

I have the following class import com.android.annotations.NonNullByDefault; @NonNullByDefault public final class Log { ... } and here is my build.gradle file (some parts omitted) apply plugin: ...
Adam's user avatar
  • 2,097
74 votes
6 answers
88k views

Task 'prepareKotlinBuildScriptModel' not found in project ':app'

I am getting this error while gradle sync. This is react native project.
Sudeep Kumar's user avatar
56 votes
15 answers
92k views

The supplied javaHome seems to be invalid. I cannot find the java executable. Tried location: C:\Program Files\Java\jdk-17\bin\java.exe

I've been pulling my hair over this for 3 days now, every time I run the command react-native run-android I get this error: info Running jetifier to migrate libraries to AndroidX. You can disable it ...
user avatar
43 votes
7 answers
41k views

React Native | Failed to install the app. Please accept all necessary SDK licenses using SDK Manager

I was trying to start running my react native project. But I'm getting this error while running the react-native run-android command. I tried a bunch of solutions that I found online but neither of ...
Dipanshu Chaubey's user avatar
41 votes
5 answers
13k views

Could not get unknown property 'manifestOutputDirectory'

I'm trying to "make project" with Android Studio, and I'm getting this error: Execution failed for task ':myApp:processGoogleDebugManifest'. Could not get unknown property '...
Sergio Viudes's user avatar
32 votes
6 answers
42k views

Cannot resolve symbol 'build' on line import com.android.build.OutputFile in app/build.gradle

So I just created a react native project using the command react-native init "project-name" I went into the app level build.gradle to connect firebase and I had an error saying could not resolve ...
Dfarrelly's user avatar
  • 735
31 votes
7 answers
12k views

Could not find aapt2-proto.jar

See this link (as I suspected) has the POM file and no jar. Important Notes: I am using latest version of react native ... v0.57.3 and also latest version of react-native-cli ... v2.0.1 at this ...
Harry's user avatar
  • 981
29 votes
3 answers
52k views

How to import react native project in android studio

I started development of the android application using atom text editor. It is working fine as long I am writing code in JS and JSX. I have to do functionality which is not available in react native,...
N Sharma's user avatar
  • 34.2k
28 votes
16 answers
40k views

Type androidx.appcompat.resources.R$dimen is defined multiple times

We have a React Native app where after upgrading to Android Studio 3.6.1 and Gradle plugin 3.6.1 we are seeing this compilation error: Type androidx.appcompat.resources.R$dimen is defined multiple ...
Andrew Aarestad's user avatar
26 votes
9 answers
40k views

First React Native App: Task :app:processDebugMainManifest FAILED

Problem I have followed the instructions as specified in https://reactnative.dev/docs/environment-setup, except for choclatey as I already have node etc. But I cannot build my app to reach the ...
CricK0es's user avatar
  • 381
26 votes
8 answers
20k views

React-Native project stuck on :app:installDebug

Every time I run my react-native project it's stuck in 99%. I've tried to run ./Gradlew clean and kill adb but nothing works. I already used my device via usb, genymotion and android studio emulator ...
Alessandro Macanha's user avatar
25 votes
3 answers
28k views

How to Integrate the React-Native project to Android-Studio?

I had tried to import the react-native project to android studio, but the "index.android.js" file is not shown in android-studio IDE.. So what I will do ?
Diwan Dhanvani's user avatar
24 votes
4 answers
32k views

Error when trying to run my React Native app on Android

I've built my React Native app and tested and troubleshooted with my iOS devices for months. Now I'm trying to built and test the app on Android for the first time. The thing is, that I keep getting ...
Simon Degn's user avatar
23 votes
4 answers
61k views

Gradle: Could not initialize class org.codehaus.groovy.runtime.InvokerHelper

I saw this gradle error: "Could not initialize class org.codehaus.groovy.runtime.InvokerHelper". I have tried multiple ways listed online to fix the issue but no luck. During the debugging, I found ...
reactnative's user avatar
22 votes
6 answers
31k views

Tools > Android menu doesn't exist in Android Studio

From the docs: To run the AVD Manager, do one of the following: In Android Studio, select Tools > Android > AVD Manager. Click AVD Manager in the toolbar. Neither of these things ...
1j01's user avatar
  • 4,050
21 votes
3 answers
23k views

Android Studio can't find runner

I cloned a project from git and built it in android studio without any problems but I don't have (Run app) in android studio and also when I run run-android I get this error: Failed to launch emulator....
mahtab's user avatar
  • 336
21 votes
7 answers
41k views

React-native (Signed) release apk keeps crashing in device

I created a signed react-native apk after following all the documents from the official react native documentation ( i.e. https://facebook.github.io/react-native/docs/signed-apk-android ). After ...
Crypticsy's user avatar
  • 780
20 votes
5 answers
110k views

"Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0." -REACT-NATIVE

I am facing this error when I am trying to run a react-native application react-native run-android, I am unable to install the application. I am trying to build a camera application. My current react-...
Akash's user avatar
  • 367
19 votes
4 answers
4k views

react-native Could not HEAD 'https://jcenter.bintray.com/com/facebook/react/react-native/maven-metadata.xml' [duplicate]

I created build yesterday and it was working fine . but when I try to create the release build today I got this. some if the question that are already asked here JCenter deprecation; impact on ...
Engr.Aftab Ufaq's user avatar
18 votes
5 answers
26k views

Expiring Daemon because JVM heap space is exhausted?

I just updated the Android Studio to 3.5.0 and I'm getting Expiring Daemon because JVM heap space is exhausted . Message while the build is running. Also, the build is taking more time to complete. ...
Dishant Chanchad's user avatar
18 votes
5 answers
32k views

Running React Native in WSL with the emulator running directly in Windows

I haven't done Android development in a while, so my knowledge of modern Android development is spotty. I'm trying to learn React Native. I use WSL as my primary development environment. Since it'll ...
Leo Jiang's user avatar
  • 25.6k
18 votes
9 answers
16k views

31.0.0 is not a valid SDK Version. Option are 26.0.0 Unversioned

I can no longer run my app after updating expo version to 31.0.0. I needed this upgrade to do due iOS version 12 support. Thou after trying to build the Android app it is no longer working. my ...
Mizlul's user avatar
  • 2,270
18 votes
2 answers
11k views

java.lang.ClassNotFoundException: Didn't find class ".MainActivity" on path: DexPathList react-native [duplicate]

I am writing a mobile app using react-native. Even though I did not touch any native side of my code, App started to be stopped just after running. I did some changes in react native components, but I ...
hayridurmaz's user avatar
17 votes
5 answers
18k views

Android Studio setting node directory for build (Cause: error=2, No such file or directory)

My project build fails because it's using the incorrect directory to run Node. How do I go about setting the Node directory for these compile-time tasks? The specific task is: app:...
Nathanael's user avatar
  • 1,001
17 votes
8 answers
46k views

The development client (com.reactnative02) for this project is not installed. Please build and install the client on the device first

I am getting the above error when previewing the react app on an android studio simulator. Please help. Here is the error: "CommandError: The development client (com.reactnative02) for this ...
Junaid khan's user avatar
17 votes
8 answers
22k views

React-Native: Error type 3: Activity class does not exist

I'm aware there's a plethora of questions/answers regarding this issue. However, I have spent the past few days trying a number of solutions I've found on SO and none have worked thus far. My error: ...
Cin88's user avatar
  • 463
17 votes
13 answers
59k views

Failed to launch emulator. Reason: Emulator exited before boot en React Native when react-native run-android

I am installing React Native according to this website https://medium.com/@leonardobrunolima/react-native-tips-setting-up-your-development-environment-for-windows-d326635604ea, it's very useful until ...
Jesús's user avatar
  • 467
16 votes
2 answers
38k views

BUG! Exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version

An error occurs when trying to build an apk: FAILURE: Build failed with an exception. * What went wrong: Could not open settings generic class cache for settings file 'C:\Ruble\flutter_project\android\...
Ruble's user avatar
  • 4,363
16 votes
3 answers
15k views

Android Studio: Cannot run program "node"

I have project in React Native, and I'm not being able to build on the Android Studio due the following error. Here's the detailed log with additional info: java.io.IOException: Cannot run program &...
Ernanni's user avatar
  • 398
16 votes
2 answers
4k views

React-Native Android - Could not find com.android.tools:common

It seems that somehow the android/tools/common library has been deleted (pom, jar). This caused many react native libraries that are using an old gradle version in their classpath (e.g com.android....
Elad Gelman's user avatar
  • 1,182
16 votes
1 answer
3k views

How React native and Android Instant Apps will play along? Any thoughts?

Google recently announced android instant app. Which basically is code splitting. Will this work with React native apps, since react native build will generate main js bundle. Any thoughts how one ...
thecachedbyte's user avatar
15 votes
2 answers
7k views

React Native: error: resource android:style/TextAppearance.Material.Widget.Button.Borderless.Colored not found

I am trying to get Facebook Login for my React Native Android project and when I try to build it with react-native run-android I am getting this error. I thought at first it was an issue with my ...
MaxPower's user avatar
  • 367
15 votes
6 answers
10k views

Android Studio Duplicate class kotlin

Duplicate class kotlin.internal.jdk7.JDK7PlatformImplementations found in modules jetified-kotlin-stdlib-1.8.0 (org.jetbrains.kotlin:kotlin-stdlib:1.8.0) and jetified-kotlin-stdlib-jdk7-1.3.31 (org....
Yusuf Jalboush's user avatar
15 votes
8 answers
68k views

How to fix Execution failed for task ':app:processDebugManifest' in React Native?

I find an error when run the project, I try to look for many examples but fail all, this is the detail of error: D:\myApp\android\app\src\debug\AndroidManifest.xml:22:18-91 Error: Attribute ...
Frank Andrew's user avatar
15 votes
5 answers
5k views

Debugger Options Not open when ctrl+m in Android Studio Bumblebee when running react native app

Debugger Options Not open when ctrl+m in Android Studio Bumblebee when running react native app
kumail khan's user avatar
15 votes
4 answers
18k views

'React native run android' stop immediatelly after start the app in emulator

I'm trying to test my Android application but when I start it with react-native run-android command after it is start on the device inmediatelly stop without error. I got this: This build could be ...
PumpkinSeed's user avatar
  • 3,054
14 votes
9 answers
18k views

Android SDK is Unavailable Upon First Startup of Android Studio

I've been trying to install Android Studio for use in creating a React Native app using Expo. As I try to install Android Studio, and run it for the first time, I arrive at the following screen: Keep ...
IPSDSILVA's user avatar
  • 1,777
14 votes
8 answers
18k views

Admob : Ad serving is limited - The number of ads you can show has been limited. For details, go to the Policy center

I'm new to admob. I published my first android app (written in expo react-native). I followed the instructions https://docs.expo.dev/versions/latest/sdk/admob/ on including admob ads in my app. But ...
Sandeep Amarnath's user avatar
14 votes
6 answers
7k views

Android NDK, Error:(165, 0) Cause: ndk-build binary cannot be found

I'm trying to run the react-native ReactAndroid project with AndroidStudio. However I get this NDK error. Error:(165, 0) Cause: ndk-build binary cannot be found, check if you've set $ANDROID_NDK ...
han4wluc's user avatar
  • 1,189
14 votes
3 answers
10k views

How to Force React Native app to be just RTL?

I have an app is written in react native and all things in the app use "Arabic Language and layout" So I want to force the app to be RTL & Layout too, so I use I18nManager from RN to do it and ...
Oliver D's user avatar
  • 2,809
14 votes
5 answers
25k views

Could not find method compile() for arguments [com.android.support:appcompat-v7:25.0.0]

Trying to build a react native project, and cannot compile appcompat Could not find method compile() for arguments [com.android.support:appcompat-v7:25.0.0] on object of type org.gradle.api....
omars's user avatar
  • 8,604
14 votes
2 answers
9k views

Expo cannot open development build on android emulator

I'm trying to run my Expo managed project on Android simulator with npx expo run:android. I have expo-dev-client installed. When I run npx expo run:android, it fails with the message: CommandError: ...
hayata_suenaga's user avatar
13 votes
2 answers
10k views

Unsupported class file major version 59 in Android Studio with ReactNative

i'm trying to reBuild and compile my Android Studio project, it worked good before installing the new version of react-native-jumio-mobilesdk for react native. After upgrading that library to 3.9.1, i ...
MayenRosil's user avatar
13 votes
2 answers
17k views

Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8

I'm trying to use a physical Android device to test/debug my React Native project. I connected the device to my Windows 11 machine via USB and turned on Developer mode on the device but when I tried ...
Sam's user avatar
  • 29.2k
13 votes
1 answer
42k views

Why React-Native Couldn't start project on Android connection with Expo?

Couldn't start project on Android. Error : No Android connected device found, and no emulators could be started automatically. Please connect a device or create an emulator (https://docs.expo.io/...
Mohsen Bakhtiyar's user avatar
13 votes
1 answer
3k views

React native generate ProGuard mapping files

I am running crash reporting with firebase and would really like to see the error stack trace. I get the message: Upload a ProGuard mapping file to deobfuscate future stack traces for version X I ...
Ally Jr's user avatar
  • 1,075
13 votes
3 answers
4k views

Android App Bundle from React Native: You uploaded an APK or Android App Bundle with invalid or missing signing information for some of its files

I'm trying to publish an app for the first time to the Google Play Store. I've opted in to Google Play Signing. I know for a fact that I'm signing the Android App Bundle with the right key since, when ...
Maximilian Krause's user avatar
12 votes
8 answers
12k views

Android Studio Electric Eel: javaHome seems to be invalid

I'm developing a React Native - TypeScript Mobile app. I updated Android Studio which has ruined the build of my app. I have spent multiple hours but I'm not able to resolve the JAVA_HOME error I keep ...
aman's user avatar
  • 365
12 votes
3 answers
15k views

'android:name' in <activity> tag must be a valid Java class name in React Native

I have just created an react-native app and building the React Native application giving me The error below. H:\App Data\ejob-app\android\app\build\intermediates\manifests\full\debug\AndroidManifest....
Dishant Chanchad's user avatar
11 votes
8 answers
31k views

gradlew assembleRelease command in react-native android is not generating the app-release.apk

I want to generate the unsigned app-release.apk without the react-packager server. I am running the following commands for that. cd react-native-project-dir react-native bundle --platform ...
Mayuri Birajdar's user avatar

1
2 3 4 5
25