-
Notifications
You must be signed in to change notification settings - Fork 146
[Regression] Xamarin.Firebase.Analytics 121.2.2 - Type androidx.lifecycle.DispatchQueue is defined multiple times #775
Comments
I am getting the same error with new .NET 7 Android project that has:
Simple repro project here: https://github.com/AlexNik4/barcode-scan-java0000 |
Duplicate |
|
@jonpryor I tried adding the Xamarin.AndroidX.Lifecycle.Common package manually. None of the versions worked: Using 2.6.1.1 I get the same error as without the manual reference: Using 2.6.1.2 (latest version): Nothing in the full error references any other lifecycle packages. |
As temp workaround try explicitly adding following PackageReferences:
and yes - please report here if workaround works. |
it`s works ! |
This was fixed. Google moves code around and that was the reason for those warnings. Try using |
Closing this issue |
@moljac thank you for the workarounds. Could you please provide additional information what to expect next?
|
You are welcome.
In general, no. We took some measures that will render that as unnecessary. The problem is that google moves types from artifact to artifact and if your real world app setup (nuget dependencies) cause that transitive dependencies reference 2 nugets/assemblies where some type appear, this error might happen. Especially with 3rd party libraries/packages/plugins which reference older packages and that is not within our control.
Simply: update to latest and be vocal that 3rd party libraries are updated. In the future I will do "alignment bumps" to ensure that published packages use always the latest, but that is for 500+ packages we maintain. If someone uses older version this error might happen again. Another reason I closed this issue - it is easier to detect if the issue is with our nuget or some 3rd party. Just this issue:
GPS-FB-MLKit was aligned week or so ago. OP's dependecy:
because it was prior to "alignment bump" |
Steps to reproduce:
Xamarin.Firebase.Analytics 121.2.0.1 works
Xamarin.Firebase.Analytics 121.2.2 does NOT work
Installed Workload Id Manifest Version Installation Source
maui-windows 7.0.86/7.0.100 VS 17.6.33712.159
maui-maccatalyst 7.0.86/7.0.100 VS 17.6.33712.159
maui-ios 7.0.86/7.0.100 VS 17.6.33712.159
maui-android 7.0.86/7.0.100 VS 17.6.33712.159
android 33.0.46/7.0.100 VS 17.6.33712.159
maccatalyst 16.4.7054/7.0.100 VS 17.6.33712.159
ios 16.4.7054/7.0.100 VS 17.6.33712.159
The text was updated successfully, but these errors were encountered: