Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ANR on BrazeCoroutineScope #215

Closed
2 tasks done
arlindiDev opened this issue Feb 10, 2022 · 4 comments
Closed
2 tasks done

ANR on BrazeCoroutineScope #215

arlindiDev opened this issue Feb 10, 2022 · 4 comments

Comments

@arlindiDev
Copy link

arlindiDev commented Feb 10, 2022

BrazeCoroutineScope.kt line 6 com.braze.coroutine.BrazeCoroutineScope.<clinit>

The crash happens only on Android 11 & Android 12

  • I have checked Braze's documentation and am still experiencing the issue.
  • I have an ANR related issue and have filled out the "ANR Reporting" section below.

Standard Reporting

What version of the Braze Android SDK are you using?

Entire ANR Report

main (runnable): tid=1 systid=11493
       at kotlinx.coroutines.Dispatchers.<clinit>(Dispatchers.kt:32)
       at kotlinx.coroutines.Dispatchers.getIO(Dispatchers.kt:134)
       at com.braze.coroutine.BrazeCoroutineScope.<clinit>(SourceFile:6)
       at com.braze.images.DefaultBrazeImageLoader.initDiskCacheTask(SourceFile:1)
       at com.braze.images.DefaultBrazeImageLoader.<init>(SourceFile:10)
       at com.appboy.Appboy.<init>(SourceFile:59)
       at com.braze.Braze.<init>(SourceFile:1)
       at com.appboy.Appboy.getInstance(SourceFile:7)
       at com.braze.Braze.getInstance(SourceFile:1)
       at com.myapp.android.braze.BrazeModule.provideBraze(BrazeModule.java:31)
       at com.myapp.android.braze.BrazeModule_ProvideBrazeFactory.provideBraze(BrazeModule_ProvideBrazeFactory.java:41)
       at com.myapp.android.app.DaggerRealApplicationComponent$SwitchingProvider.get3(DaggerRealApplicationComponent.java:23475)
       at com.myapp.android.app.DaggerRealApplicationComponent$SwitchingProvider.get(DaggerRealApplicationComponent.java:23905)
       at dagger.internal.DoubleCheck.get(DoubleCheck.java:47)
       at com.myapp.android.app.DaggerRealApplicationComponent.injectRealmyappApplication(DaggerRealApplicationComponent.java:7559)
       at com.myapp.android.app.DaggerRealApplicationComponent.inject(DaggerRealApplicationComponent.java:7335)
       at com.myapp.android.app.RealmyappApplication.inject(RealmyappApplication.java:78)
       at com.myapp.android.myappApplication.onCreate(myappApplication.java:206)
       at com.myapp.android.app.RealmyappApplication.onCreate(RealmyappApplication.java:34)
       at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1192)
       at android.app.ActivityThread.handleMakeApplication(ActivityThread.java:7545)
       at android.app.ActivityThread.handleBindApplication(ActivityThread.java:7484)
       at android.app.ActivityThread.access$1400(ActivityThread.java:301)
       at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2156)
       at android.os.Handler.dispatchMessage(Handler.java:106)
       at android.os.Looper.loop(Looper.java:246)
       at android.app.ActivityThread.main(ActivityThread.java:8550)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)
@radixdev
Copy link
Contributor

  1. What's your kotlin coroutine version?
  2. What's your kotlin std lib version?
  3. Are you using R8? If so, can you post the version being used or your Android Gradle Plugin version?

@radixdev
Copy link
Contributor

Hi @arlindiDev ,

This appears to be an issue with the underlying coroutines dependency. See Kotlin/kotlinx.coroutines#3180.

@radixdev
Copy link
Contributor

Hi @arlindiDev ,

SDK 19.0.0 directly addresses the ANR issues in the SDK. However, the kotlin coroutine issue (Kotlin/kotlinx.coroutines#3180) our team raised is still present so depending on your version of kotlin coroutines you still may continue to see issues.

@radixdev
Copy link
Contributor

radixdev commented Apr 6, 2022

Hi @arlindiDev ,

Please update your kotlin coroutine version to 1.6.1+ and Braze Android 19.0.0+ to resolve the issue. See Kotlin/kotlinx.coroutines#3180 for more information.

@radixdev radixdev closed this as completed Apr 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants