AppLovin / AppLovin-MAX-Unity-Plugin

125 stars 33 forks source link

Android NullPointerException Crash - Unity 2021.3.43 / MAX 6.6.3 / Liftoff 7.4.0.0 #433

Open NickBogovich opened 6 days ago

NickBogovich commented 6 days ago

MAX Plugin Version

6.6.3

Unity Version

2021.3.43

Device/Platform Info

Android

Crashes/ANRs per Day

10

Percentage of Users Affected

4%

First Occurrence of Crash/ANR

Crash started happening once we updated MAX from 6.4.3 to 6.6.3 and Liftoff from 6.12.1.1 to 7.4.0.0 on Android.

Exception and Stack Trace

Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List com.safedk.android.analytics.brandsafety.InterstitialFinder.a(java.lang.String, java.lang.String)' on a null object reference at com.safedk.android.analytics.brandsafety.creatives.CreativeInfoManager.a (SourceFile:262) at com.safedk.android.analytics.brandsafety.creatives.CreativeInfoManager.a (SourceFile:255) at com.safedk.android.analytics.brandsafety.BrandSafetyUtils.onShouldOverrideUrlLoading (SourceFile:2151) at com.vungle.ads.internal.ui.VungleWebClient.shouldOverrideUrlLoading at android.webkit.WebViewClient.shouldOverrideUrlLoading (WebViewClient.java:83) at org.chromium.android_webview.AwContentsClientBridge.shouldOverrideUrlLoading (chromium-TrichromeWebViewGoogle6432.aab-stable-666807033:124) at android.os.MessageQueue.nativePollOnce at android.os.MessageQueue.next (MessageQueue.java:342) at android.os.Looper.loopOnce (Looper.java:183) at android.os.Looper.loop (Looper.java:362) at android.app.ActivityThread.main (ActivityThread.java:8448) at java.lang.reflect.Method.invoke at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:552) at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:992)

How to Reproduce

Appears to happen when we load an interstitial from Vungle/Liftoff

Reproducible in the demo app?

Not Tested

Additional Info

No response

alvarshahanji commented 6 days ago

@NickBogovich it is coming from Vungle SDK and not the adapter. Could you report it to the Vungle team?

NickBogovich commented 2 days ago

I reported this issue to Vungle, and the Vungle team responded with this:

The provider of Liftoff Monetize - Vungle Android SDK v7 (com.vungle:vungle-ads) added this note on Sep 17: "Not caused by SDK: Thanks for reporting this crash. Based on the crash stack trace, the NullPointerException occurs on safedk. Please contact with safeDK about this crash."

I don't know who is in the right, but this sounds like an issue the two of you need to discern. All I know is that this issue is causing a significant amount of crashes in our app.

alvarshahanji commented 2 days ago

@NickBogovich sorry, I missed that. Which version of AdReview SDK have you integrated?

NickBogovich commented 2 days ago

How can I verify which version is integrated?

We are using AppLovin MAX and have the Enable MAX Ad Review checkbox enabled, so I'm guessing it would've pulled in whatever version of AdReview SDK was available on September 24 at 12:30p ET.

alvarshahanji commented 2 days ago

@NickBogovich could you share mediation debugger with us?

NickBogovich commented 2 days ago

Mediation Debugger says:

MAX SDK Version: 12.6.1 Plugin Version: Max-Unity-6.6.3 Ad Review Version: 5.4.6

alvarshahanji commented 2 days ago

Thank you.

Are you able to reproduce this issue on your end?

Could you share the app details and steps to repro if you are able to repro the issue with Vungle ads?

NickBogovich commented 2 days ago

I was able to reproduce it in the Mediation Debugger by playing a Vungle Rewarded ad unit. It took about 8-10 ads before it happened, but it did eventually happen with a similar crash and stack:

Caused by java.lang.NullPointerException
Attempt to invoke virtual method 'java.util.List com.safedk.android.analytics.brandsafety.InterstitialFinder.a(java.lang.String, java.lang.String)' on a null object reference

com.safedk.android.analytics.brandsafety.creatives.CreativeInfoManager.a (SourceFile:262)
com.safedk.android.analytics.brandsafety.creatives.CreativeInfoManager.a (SourceFile:255)
com.safedk.android.analytics.brandsafety.BrandSafetyUtils.onShouldOverrideUrlLoading (SourceFile:2151)
com.vungle.ads.internal.ui.VungleWebClient.shouldOverrideUrlLoading (Unknown Source:13)
android.webkit.WebViewClient.shouldOverrideUrlLoading (WebViewClient.java:83)
org.chromium.android_webview.AwContentsClientBridge.shouldOverrideUrlLoading (chromium-TrichromeWebViewGoogle6432.aab-stable-666807033:124)
android.os.MessageQueue.nativePollOnce (MessageQueue.java)
NickBogovich commented 2 days ago

The odd thing seems to be that there is a call to an InterstitialFinder method when I was attempting to display a RewardedVideo -- not sure if that has anything to do with it.

NickBogovich commented 2 days ago

Also, based on when this crash appeared in our logs, the issue may have been introduced between Ad Review 5.4.0 and 5.4.5.

alvarshahanji commented 1 day ago

@NickBogovich good to know you were able to repro. Thanks for the additional info.

  1. As requested before, could you share the app details and steps to repro?
  2. Could you try reproducing the issue using demo app as well?
  3. Could you check if the crash is still reproducible with the latest Ad Review 5.5.0?
NickBogovich commented 1 day ago

Re: app in question and repro steps -- the app in question is Play To Win Casino on Android (net.playtowingames.casino), and the steps to reproduce are to display a rewarded video when requested, and sometimes when a Liftoff Monetize RV ad is displayed, the app seems to crash upon closing the ad. This is also the case when a Liftoff RV ad was showed via the Mediation Debugger --- on occasion, closing the ad would result in the crash.

I will try later today to reproduce the crash with the latest Ad Review 5.5.0.

alvarshahanji commented 10 hours ago

@NickBogovich I could not repro the crash on my device using your app. I watched multiple LiftOff ads using mediation debugger.

  1. Is the issue device specific? Have you tried on multiple devices?
  2. Were you able to reproduce on our demo app?
  3. Let us know id the crash is resolved with Ad Review 5.5.0