LottieXamarin
LottieXamarin copied to clipboard
Dependency issue with Square.OkIO
🐛 Bug Report
When building with SDK Linking mode I'm getting an error related to the Square.OkIO dependency. I'm referencing another project that's using the latest version of Square.OkIO.
The error I'm getting is the following:
/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Legacy.targets(649,5): error XALNK7000: Mono.Linker.MarkException: Error processing method: 'Airbnb.Lottie.Parsers.Moshi.JsonReader Airbnb.Lottie.Parsers.Moshi.JsonReader::Of(Square.OkIO.IBufferedSource)' in assembly: 'Airbnb.Lottie.dll' ---> Mono.Cecil.ResolutionException: Failed to resolve Square.OkIO.IBufferedSource
Version: 4.2.2
Platform:
- [ ] :robot: Android
Having the same issue. Trying to find a solution to this....
@mttpvn I resolved this with the following package:
-
Square.OkHttp3
v4.9.2
I am having a similar issue but with AndroidX.Collection : Error XALNK7000 : Mono.Linker.MarkException: Error processing method: 'AndroidX.Collection.SparseArrayCompat Com.Airbnb.Lottie.LottieComposition::get_Characters()' in assembly: 'Lottie.Android.dll'.
I am having a similar issue but with AndroidX.Collection : Error XALNK7000 : Mono.Linker.MarkException: Error processing method: 'AndroidX.Collection.SparseArrayCompat Com.Airbnb.Lottie.LottieComposition::get_Characters()' in assembly: 'Lottie.Android.dll'.
Hi @PavloLukianets , did you find the solution? I am also having the same error.
@AlejandroLemusR adding my two cents I just started getting the exact issue you mentioned regarding AndroidX.Collection
and we have since dropped the LottieXamarin
nuget, its now working again. I think you need to get the right NuGet versions for a successful build but it seemed to fragile trying to maintain support for Lottie as other NuGet need to be updated time to time.
Hopefully we can bring it back when we migrate to MAUI eventually.
Related: #398
AppCompat did not resolve the issue mentioned by @PavloLukianets and @AlejandroLemusR. Anyone got any solutions to the issue? We need to update other nuggets due to critical safety and crash updates.