Samn
Samn

Reputation: 111

React Native App crashes on android 11 on launch without giving error

enter image description here

this is my build.gradle setting and this is my system info enter image description here

I'm trying to run the react native app on android 11 but it is keep crashing on launch without giving any error I have tries almost every solution including setting in build.gradle

buildToolsVersion = "30.0.0"
minSdkVersion = 21
compileSdkVersion = 30
targetSdkVersion = 30
supportLibVersion = "30.0.0"
ndkVersion = "20.1.5948944"
multiDexEnabled = true

setting ** target API to"30" ** in AndroidManifest.xml

the Gradle version I'm using is Gradle plugin version is 4.1.3 Gradle version is 6.7**

please help me find the solution in this regard thanks

Upvotes: 9

Views: 10822

Answers (2)

Yossi
Yossi

Reputation: 6027

This answer has been provided by manohar-octifi (github discussion):

If you are using @sentry/react-native and the version is lower than 2.0.0, then update the version to 2.0.0 or higher (I updated to 2.2.0). This should fix the problem.

Upvotes: 7

Gigarthan
Gigarthan

Reputation: 247

I got an error like this when setting targetSdk version to 30 it's happening because of okhttp version and fixed it by using the latest version

implementation("com.squareup.okhttp3:okhttp:4.9.1")
implementation("com.squareup.okhttp3:okhttp-urlconnection:4.9.1")

add this in your android/app/build.gradle

Upvotes: 12

Related Questions