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

ListenableFuture issues with Firebase.Analytics #1012

Open
dmanning23 opened this issue Oct 16, 2024 · 0 comments
Open

ListenableFuture issues with Firebase.Analytics #1012

dmanning23 opened this issue Oct 16, 2024 · 0 comments

Comments

@dmanning23
Copy link

dmanning23 commented Oct 16, 2024

Android framework version

net8.0-android

Affected platform version

VS 2022 17.11.5

Description

I am trying to add Firebase.Analytics to an Android Maui project, and getting ListenableFuture compilation errors:
Type com.google.common.util.concurrent.ListenableFuture is defined multiple times

I have tried installing the Nuget packages as described in #764 as well as implemented the escape hatches as described in #535 but am still getting the error.

A full reproduction of the error can be found here:
https://github.com/dmanning23/MauiAppListenableFutureBug
This project is just a "hello world" Maui app with the relevant packages added.

Here is the project file, which shows the installed packages and Guava escape hatches:
https://github.com/dmanning23/MauiAppListenableFutureBug/blob/master/MauiAppListenableFutureBug/MauiAppListenableFutureBug.csproj

The full error text can be found below.

If I had to guess, there is "code stink" in the Xamarin.Google.Guava nuget package, which has a dependency of Xamarin.Google.Guava.ListenableFuture >= 9999.0.0
which is an unlisted package. This dependency is preventing me from updating to the latest ListenableFuture package.
https://www.nuget.org/packages/Xamarin.Google.Guava#dependencies-body-tab

Please advise, I've been spinning my wheels on this problem and not sure how to move forward or debug this error.

Relevant log output

1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.S0.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:82)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.S0.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:32)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.S0.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:31)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.S0.b(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:2)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.D8.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:42)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.D8.b(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:13)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.D8.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:40)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.S0.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:122)
1>MSBUILD : java.exe error JAVA0000: 	... 1 more
1>MSBUILD : java.exe error JAVA0000: Caused by: com.android.tools.r8.utils.b: Type com.google.common.util.concurrent.ListenableFuture is defined multiple times: obj\Debug\net8.0-android\lp\261\jl\libs\FD9B36150054C73C.jar:com/google/common/util/concurrent/ListenableFuture.class, obj\Debug\net8.0-android\lp\294\jl\libs\D32451BA8E08B29F.jar:com/google/common/util/concurrent/ListenableFuture.class
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.Q2.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:21)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.D2.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:54)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.D2.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:10)
1>MSBUILD : java.exe error JAVA0000: 	at java.base/java.util.concurrent.ConcurrentHashMap.merge(ConcurrentHashMap.java:2056)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.D2.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:6)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.graph.m4$a.d(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:6)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.dex.c.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:61)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.dex.c.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:12)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.dex.c.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:9)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.D8.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:45)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.D8.d(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:17)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.D8.c(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:69)
1>MSBUILD : java.exe error JAVA0000: 	at com.android.tools.r8.utils.S0.a(R8_8.2.33_429c93fd24a535127db6f4e2628eb18f2f978e02f99f55740728d6b22bef16dd:28)
1>MSBUILD : java.exe error JAVA0000: 	... 6 more
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