Closed jpobst closed 1 day ago
When do we have these changes rolled out? I really need it for my projects.
@tuyen-vuduc As a poor man's workaround - downgrade lifecycle libraries to 2.7.0, appcompat to 1.6.1 in android project, and similarly in .net project. It works then until this new fix is released.
Context: https://github.com/xamarin/AndroidX/pull/863 Fixes: https://github.com/dotnet/android/issues/9049 Fixes: https://github.com/xamarin/AndroidX/issues/909
In version
2.8.*
, Google moved all the types in 2 libraries into 2 new libraries:Xamarin.AndroidX.Lifecycle.Common
toXamarin.AndroidX.Lifecycle.Common.Jvm
.Xamarin.AndroidX.Lifecycle.ViewModel
toXamarin.AndroidX.Lifecycle.ViewModel.Android
.While this is a source compatible change for users, it is not a binary compatible change for users that are relying on NuGets or assemblies that have not been recompiled.
These types may continue to work in Debug builds, but the linker and AOT compiler steps run for Release builds are unable to resolve the moved types, causing unfixable errors (other than recompiling all assemblies).
Adding
[TypeForwardedToAttribute]
attributes allows the linker and AOT to succeed without recompiling old assemblies.