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

java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics #102

Open
johnn82 opened this issue Nov 15, 2021 · 0 comments

Comments

@johnn82
Copy link

johnn82 commented Nov 15, 2021

Version Number of Plugin: 4.0.1
Device Tested On: Xperia XZ2 Android 10
Simulator Tested On: Pixel 2 Android 11 (Google Play)
Version of VS: 2019
Version of Xamarin: 16.11

Steps to reproduce the Behavior

NOTE: the error occours only when launching the app not compiling it!

DevOps virtual agent used: windows-2019
https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md

Building Xamarin.Forms app using Microsoft Azure DevOps pipeline create an APK that CRASH with this error.

Time	Device Name	Type	PID	Tag	Message
11-15 16:47:16.785	pixel_2_r_11_0_-_api_30	Info	5937	MonoDroid	java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics;
	at com.facebook.internal.FacebookInitProvider.<clinit>(FacebookInitProvider.kt:14)
	at java.lang.Class.newInstance(Native Method)
	at android.app.AppComponentFactory.instantiateProvider(AppComponentFactory.java:147)
	at androidx.core.app.CoreComponentFactory.instantiateProvider(CoreComponentFactory.java:67)
	at android.app.ActivityThread.installProvider(ActivityThread.java:7228)
	at android.app.ActivityThread.installContentProviders(ActivityThread.java:6780)
	at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6697)
	at android.app.ActivityThread.access$1300(ActivityThread.java:237)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1913)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loop(Looper.java:223)
	at android.app.ActivityThread.main(ActivityThread.java:7656)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)

Expected Behavior

App should run normally without crashing

Actual Behavior

App crash when launching the one compiled using an Azure DevOps build pipeline.
App runs fine when compiled, either in Debug or in Release, using Visual Studio 2019.

The error seems to be related to this:
xamarin/XamarinComponents#603.

NOTE: Adding reference to https://www.nuget.org/packages/Xamarin.Kotlin.StdLib/1.5.31.2 solved the problem!

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

1 participant