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

Bug: Didn't find class "android.os.OutcomeReceiver" on initialization #594

Closed
jesphinpt opened this issue Nov 30, 2023 · 12 comments
Closed

Comments

@jesphinpt
Copy link

jesphinpt commented Nov 30, 2023

MAX SDK Version:

12.0.0

Platform:

Android

Error Description:

I am getting the error as Caused by: java.lang.ClassNotFoundException: Didn't find class "android.os.OutcomeReceiver".

My application has the sourceCompatibility as 17. Our app needs the latest JDK version because some dependency needs this as mandatory.

 compileOptions {
        sourceCompatibility JavaVersion.VERSION_17
        targetCompatibility JavaVersion.VERSION_17
    }

ApplovinSDK has sourceCompatibility as 1.8.

Is the error happening due to the incompatible versions used between the app and the library?

Error:

Caused by: java.lang.ClassNotFoundException: Didn't find class "android.os.OutcomeReceiver" on path: DexPathList[[zip file "/data/app/com.app-djB6VrA==/base.apk"],nativeLibraryDirectories=[/data/com.app-cmG8YuLpwuIfPZUdjB6VrA==/lib/arm64, /data/app/com.app--cmG8YuLpwuIfPZUdjB6VrA==/base.apk!/lib/arm64-v8a, /system/lib64, /system/vendor/lib64]]
 at java.lang.Class dalvik.system.BaseDexClassLoader.findClass(java.lang.String) (BaseDexClassLoader.java:125)
 at java.lang.Class java.lang.ClassLoader.loadClass(java.lang.String, boolean) (ClassLoader.java:379)
 at java.lang.Class java.lang.ClassLoader.loadClass(java.lang.String) (ClassLoader.java:312)
 at boolean com.applovin.impl.sdk.aa.Fr() (SourceFile:209)
 at java.util.Map com.applovin.impl.sdk.o.CV() (SourceFile:396)
 at void com.applovin.impl.sdk.o.<init>(com.applovin.impl.sdk.n) (SourceFile:177)
 at void com.applovin.impl.sdk.n.Bh() (SourceFile:457)
 at void com.applovin.impl.sdk.n.a(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:415)
 at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:425)
 at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:374)
 at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(android.content.Context) (SourceFile:350)
 at void com.com.app-.onCreate() (ExampleApp.kt:19)
 at void android.app.Instrumentation.callApplicationOnCreate(android.app.Application) (Instrumentation.java:1120)
 at void android.app.ActivityThread.handleBindApplication(android.app.ActivityThread$AppBindData) (ActivityThread.java:5826)
 at void android.app.ActivityThread.-wrap1(android.app.ActivityThread, android.app.ActivityThread$AppBindData) (ActivityThread.java:-1)
 at void android.app.ActivityThread$H.handleMessage(android.os.Message) (ActivityThread.java:1685)
 at void android.os.Handler.dispatchMessage(android.os.Message) (Handler.java:106)
 at void android.os.Looper.loop() (Looper.java:176)
 at void android.app.ActivityThread.main(java.lang.String[]) (ActivityThread.java:6651)
 at java.lang.Object java.lang.reflect.Method.invoke(java.lang.Object, java.lang.Object[]) (Method.java:-2)
  at void com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run() (RuntimeInit.java:547)
  at void com.android.internal.os.ZygoteInit.main(java.lang.String[]) (ZygoteInit.java:824)

Rejecting re-init on previously-failed class java.lang.Class<com.applovin.impl.sdk.aa$3>: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/os/OutcomeReceiver;
@jesphinpt jesphinpt changed the title Bug: Caused by: java.lang.ClassNotFoundException: Didn't find class "android.os.OutcomeReceiver" on path:DexPathList[[zip file "/data/app/example-cmA==/base.apk" Bug: Caused by: java.lang.ClassNotFoundException: Didn't find class "android.os.OutcomeReceiver" on initialization Nov 30, 2023
@jesphinpt jesphinpt changed the title Bug: Caused by: java.lang.ClassNotFoundException: Didn't find class "android.os.OutcomeReceiver" on initialization Bug: Didn't find class "android.os.OutcomeReceiver" on initialization Nov 30, 2023
@santoshbagadi
Copy link
Contributor

@jesphinpt do you mind sharing the device type and device OS version that this is running on.

@jesphinpt
Copy link
Author

jesphinpt commented Dec 1, 2023

I have checked with

Android 13 *Pixel XL"
Android 8.1.0 Redmi

@tiandrew
Copy link
Contributor

tiandrew commented Dec 1, 2023

Thanks @jesphinpt. The source and target compatibility versions should not be an issue as long as you are above the min SDK version of 16. Just to verify, it sounds like this crash should only be happening on the Android 8.1.0 Redmi right?

@tiandrew
Copy link
Contributor

tiandrew commented Dec 4, 2023

Hey @jesphinpt, our latest SDK release 12.1.0 should fix this issue.

@tiandrew tiandrew closed this as completed Dec 4, 2023
@jesphinpt
Copy link
Author

jesphinpt commented Dec 11, 2023

@tiandrew Still facing the error with the version 12.1.0. Caused by: java.lang.ClassNotFoundException: Didn't find class "android.os.OutcomeReceiver" on path: DexPathList[[zip file "/data/app/exampleapp-_B3Irpb43VrFAwMvTQphJg==/base.apk"],nativeLibraryDirectories=[/data/app/exampleapp-_B3Irpb43VrFAwMvTQphJg==/lib/arm64, /system/lib64, /system/vendor/lib64]]

@tiandrew tiandrew reopened this Dec 11, 2023
@tiandrew
Copy link
Contributor

Hey @jesphinpt can you try reproducing the issue on our demo app here and sending it to me? It's not clear what could be causing the issue if our fix in 12.1.0 didn't help.

@MapleSimon
Copy link

For what it's worth, I'm also seeing my share of:

Rejecting re-init on previously-failed class java.lang.Class<com.applovin.impl.sdk.aa$a>: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/os/OutcomeReceiver;
[...]
Caused by: java.lang.ClassNotFoundException: Didn't find class "android.os.OutcomeReceiver" on path: DexPathList[[zip file "/data/app/com.org.project-ZZziwPT1H6ShfKjNCqBSJw==/base.apk"],nativeLibraryDirectories=[/data/app/com.org.project-ZZziwPT1H6ShfKjNCqBSJw==/lib/arm64, /data/app/com.org.project-ZZziwPT1H6ShfKjNCqBSJw==/base.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]

I'm also on Java 8:

    compileOptions {
        sourceCompatibility = JavaVersion.VERSION_1_8
        targetCompatibility = JavaVersion.VERSION_1_8
    }

Errors when initializing MAX SDK 12.1.0 on my Android v8.1.0 phone.

I don't know what the impact of this is since ads are still loading. It just doesn't look good to see on init.

@rbyjoswald
Copy link

Seeing the same here. Just updated AppLovin including all mediations to the latest version and this started to appear.
Unity Version: 2022.3.16f1
Applovin Max For Unity Version: 6.1.2 (12.1.0 for Android & iOS)

The testing-device is an Android 8.1 tablet.

2024.01.09 16:49:33.231 9947 10108 Info zygote Rejecting re-init on previously-failed class java.lang.Class<com.applovin.impl.sdk.aa$a>: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/os/OutcomeReceiver; 2024.01.09 16:49:33.231 9947 10108 Info zygote at boolean com.applovin.impl.sdk.aa.M(android.content.Context) (SourceFile:211) 2024.01.09 16:49:33.231 9947 10108 Info zygote at java.util.Map com.applovin.impl.sdk.o.CY() (SourceFile:396) 2024.01.09 16:49:33.231 9947 10108 Info zygote at void com.applovin.impl.sdk.o.<init>(com.applovin.impl.sdk.n) (SourceFile:177) 2024.01.09 16:49:33.231 9947 10108 Info zygote at void com.applovin.impl.sdk.n.Bj() (SourceFile:457) 2024.01.09 16:49:33.231 9947 10108 Info zygote at void com.applovin.impl.sdk.n.a(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:415) 2024.01.09 16:49:33.231 9947 10108 Info zygote at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:425) 2024.01.09 16:49:33.231 9947 10108 Info zygote at com.applovin.sdk.AppLovinSdk com.applovin.mediation.unity.MaxUnityAdManager.initializeSdkWithCompletionHandler(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, com.applovin.mediation.unity.MaxUnityAdManager$BackgroundCallback, com.applovin.mediation.unity.MaxUnityAdManager$Listener) (MaxUnityAdManager.java:253) 2024.01.09 16:49:33.231 9947 10108 Info zygote at void com.applovin.mediation.unity.MaxUnityPlugin.initializeSdk(java.lang.String, java.lang.String, com.applovin.mediation.unity.MaxUnityAdManager$BackgroundCallback) (MaxUnityPlugin.java:98)

@santoshbagadi
Copy link
Contributor

@rbyjoswald wanted to double check if this is this causing a crash on the app? Or if it is just error logs but the ads are loading fine?

If it's the later, we'll look into removing the log in a future SDK release.

@rbyjoswald
Copy link

@santoshbagadi No crash on the app. Just a lot (tens, maybe hundreds) of those same stacks in the log. Like the commenter before me, this gives me an uneasy feeling. Ads seemed to show up in the app and the max in-app-diagnostics tool showed everything has initialized correctly.

@vokruttabtale
Copy link

vokruttabtale commented Jan 17, 2024

Hey, we have the same issue, after our investigation we've found out that these errors are coming from the line
AppLovinSdk.getInstance(this).mediationProvider = "max" what called before AppLovinSdk.initializeSdk(this). It's done according to your manual. We started to face the issue after updating SDK to 12.1.0, and downgrading back to 11.11.3 resolves the issue.

I Rejecting re-init on previously-failed class java.lang.Class<com.applovin.impl.sdk.aa$a>: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/os/OutcomeReceiver;
I at boolean com.applovin.impl.sdk.aa.M(android.content.Context) (SourceFile:211)
I at java.util.Map com.applovin.impl.sdk.o.CY() (SourceFile:396)
I at void com.applovin.impl.sdk.o.(com.applovin.impl.sdk.n) (SourceFile:177)
I at void com.applovin.impl.sdk.n.Bj() (SourceFile:457)
I at void com.applovin.impl.sdk.n.a(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:415)
I at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:425)
I at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:374)
I at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(android.content.Context) (SourceFile:350)
I at boolean com.applovin.impl.sdk.aa.M(android.content.Context) (SourceFile:211)
I at java.util.Map com.applovin.impl.sdk.o.CY() (SourceFile:396)
I at void com.applovin.impl.sdk.o.(com.applovin.impl.sdk.n) (SourceFile:177)
I at void com.applovin.impl.sdk.n.Bj() (SourceFile:457)
I at void com.applovin.impl.sdk.n.a(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:415)
I at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(java.lang.String, com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:425)
I at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(com.applovin.sdk.AppLovinSdkSettings, android.content.Context) (SourceFile:374)
I at com.applovin.sdk.AppLovinSdk com.applovin.sdk.AppLovinSdk.getInstance(android.content.Context) (SourceFile:350)`

@santoshbagadi
Copy link
Contributor

As mentioned earlier, we'll look into removing these logs in a future SDK version, but they shouldn't cause any issues with loading and displaying ads. This shouldn't cause any crashes, just error logs from Android OS.

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

6 participants