9.4.1.0
Windows 10 Build 18362
71.1610.0
This is a continuation from #239 which wasn't fixed at all.
Everytime when you try to make any type of call to Firestore, the App will crash with the below exception. The important part is that, according to the stack trace, the "io.opencensus.tags.Tags" class is missing.
Also you can download the file from This comment
08-27 22:19:56.699 E/AndroidRuntime(22875): FATAL EXCEPTION: main
08-27 22:19:56.699 E/AndroidRuntime(22875): Process: cl.kitratech.kitracompanion, PID: 22875
08-27 22:19:56.699 E/AndroidRuntime(22875): java.lang.RuntimeException: Internal error in Firestore (0.6.6-dev).
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.google.firebase.firestore.g.zza.zzb(com.google.firebase:firebase-firestore@@17.0.5:324)
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.google.firebase.firestore.g.zzd.run(Unknown Source:2)
08-27 22:19:56.699 E/AndroidRuntime(22875): at android.os.Handler.handleCallback(Handler.java:873)
08-27 22:19:56.699 E/AndroidRuntime(22875): at android.os.Handler.dispatchMessage(Handler.java:99)
08-27 22:19:56.699 E/AndroidRuntime(22875): at android.os.Looper.loop(Looper.java:193)
08-27 22:19:56.699 E/AndroidRuntime(22875): at android.app.ActivityThread.main(ActivityThread.java:6715)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.lang.reflect.Method.invoke(Native Method)
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:911)
08-27 22:19:56.699 E/AndroidRuntime(22875): Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Lio/opencensus/tags/Tags;
08-27 22:19:56.699 E/AndroidRuntime(22875): at io.grpc.internal.CensusStatsModule.(CensusStatsModule.java:84)
08-27 22:19:56.699 E/AndroidRuntime(22875): at io.grpc.internal.AbstractManagedChannelImplBuilder.getEffectiveInterceptors(AbstractManagedChannelImplBuilder.java:426)
08-27 22:19:56.699 E/AndroidRuntime(22875): at io.grpc.internal.AbstractManagedChannelImplBuilder.build(AbstractManagedChannelImplBuilder.java:410)
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.google.firebase.firestore.f.zzd.(com.google.firebase:firebase-firestore@@17.0.5:102)
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.google.firebase.firestore.b.zzg.zza(com.google.firebase:firebase-firestore@@17.0.5:1217)
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.google.firebase.firestore.b.zzi.run(Unknown Source:8)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:458)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.util.concurrent.FutureTask.run(FutureTask.java:266)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:301)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
08-27 22:19:56.699 E/AndroidRuntime(22875): at com.google.firebase.firestore.g.zza$zza.run(com.google.firebase:firebase-firestore@@17.0.5:190)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.lang.Thread.run(Thread.java:764)
08-27 22:19:56.699 E/AndroidRuntime(22875): Caused by: java.lang.ClassNotFoundException: Didn't find class "io.opencensus.tags.Tags" on path: DexPathList[[zip file "/data/app/cl.kitratech.kitracompanion-0hZTWOZ199kbkNK_AXax2g==/base.apk"],nativeLibraryDirectories=[/data/app/cl.kitratech.kitracompanion-0hZTWOZ199kbkNK_AXax2g==/lib/arm64, /data/app/cl.kitratech.kitracompanion-0hZTWOZ199kbkNK_AXax2g==/base.apk!/lib/arm64-v8a, /system/lib64]]
08-27 22:19:56.699 E/AndroidRuntime(22875): at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
08-27 22:19:56.699 E/AndroidRuntime(22875): at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
08-27 22:19:56.699 E/AndroidRuntime(22875): ... 13 more
Java.Lang.RuntimeException: 'Internal error in Firestore (0.6.6-dev).'
interesting
our tooling incorrectly reported transitive dependencies.
opencensuse artifacts are being bound.
Seems that our dependency detection tool has some issues with transitive dependencies.
opencensus libraries are telemetry libraries used by google.
The highest priority is to finish those bindings ASAP.
Duplicates
Xamarin.Firebase.Firestore 71.1705.0 since Preview3 doesn't work #239
https://github.com/xamarin/GooglePlayServicesComponents/issues/239
Firebase Firestore version 71.1705.0 not working #233
https://github.com/xamarin/GooglePlayServicesComponents/issues/233
Is there any workaround to make this working? I'm working on a big project and we are stuck because of this issue. I'm not able to downgrade to a lower version because if I do that, other parts of the project stop working
Same problem here. Since Azure Mobile Apps won鈥檛 be available after November 11th, this was our fallback. There will probably be more people in the same scenario.
@akamud @guillermo-gerard @xamarindevelopervietnam @JPZV
TL;DR: I'm actively working on this issue!
Details:
new versions of firebase have dependencies on newer versions of gRPC (Xamarin.Google.Grpc nugets) which introduced new dependencies (io.opencensus and grpc-context).
I finished binding OpenCensus
https://www.nuget.org/packages/Xamarin.Io.OpenCensus.OpenCensusApi/
https://www.nuget.org/packages/Xamarin.Io.OpenCensus.OpenCensusContribGrpcMetrics/
but grpc-context is not trivial (tons of errors I'm working through)
I beg for your patience.
thanks for your update @moljac !
hope you will finish ASAP!
Doing my best.
any progress?
A lot, but hit some blockers on CI during samples builds
@JPZV @xamarindevelopervietnam @akamud @guillermo-gerard
The issue should be fixed in version 71.20190927
Packages:
Please update your packages and provide us feedback here (or even close the issue if issue is fixed)
Thanks
@moljac
It's works, but I had to install Guava (Xamarin.Google.Guava v27.1.0) otherwise Firestore will throw this exception:
[0:] Java.Lang.NoClassDefFoundError: Failed resolution of: Lcom/google/common/base/Preconditions; ---> Java.Lang.ClassNotFoundException: Didn't find class "com.google.common.base.Preconditions" on path: DexPathList[[zip file "/data/app/cl.kitratech.kitracompanion-86ZcHOAeuYsHtMXNf4Zy9w==/base.apk"],nativeLibraryDirectories=[/data/app/cl.kitratech.kitracompanion-86ZcHOAeuYsHtMXNf4Zy9w==/lib/arm64, /data/app/cl.kitratech.kitracompanion-86ZcHOAeuYsHtMXNf4Zy9w==/base.apk!/lib/arm64-v8a, /system/lib64]]
--- End of inner exception stack trace ---
at Java.Interop.JniEnvironment+StaticMethods.CallStaticObjectMethod (Java.Interop.JniObjectReference type, Java.Interop.JniMethodInfo method, Java.Interop.JniArgumentValue* args) [0x00069] in:0
at Java.Interop.JniPeerMembers+JniStaticMethods.InvokeObjectMethod (System.String encodedMember, Java.Interop.JniArgumentValue* parameters) [0x00018] in:0
at Firebase.Firestore.FirebaseFirestore.GetInstance (Firebase.FirebaseApp app) [0x00031] in:0
at FirebaseTest.Droid.FirestoreService.get_Instance () [0x00001] in E:\Users\juanp\Documents\Visual Studio\Tmp Projects\FirebaseTest\FirebaseTest\FirebaseTest.Android\FirestoreService.cs:38
at FirebaseTest.Droid.FirestoreService.GetCommunity () [0x00018] in E:\Users\juanp\Documents\Visual Studio\Tmp Projects\FirebaseTest\FirebaseTest\FirebaseTest.Android\FirestoreService.cs:63
--- End of managed Java.Lang.NoClassDefFoundError stack trace ---
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/common/base/Preconditions;
at com.google.firebase.firestore.FirebaseFirestore.zza(com.google.firebase:firebase-firestore@@17.0.5:64)
at com.google.firebase.firestore.FirebaseFirestore.getInstance(com.google.firebase:firebase-firestore@@17.0.5:58)
at md515f54ada9f5b71d04f64fd20e19f660f.MainActivity.n_onCreate(Native Method)
at md515f54ada9f5b71d04f64fd20e19f660f.MainActivity.onCreate(MainActivity.java:30)
at android.app.Activity.performCreate(Activity.java:7136)
at android.app.Activity.performCreate(Activity.java:7127)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2926)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3081)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1838)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:6715)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:911)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.common.base.Preconditions" on path: DexPathList[[zip file "/data/app/cl.kitratech.kitracompanion-86ZcHOAeuYsHtMXNf4Zy9w==/base.apk"],nativeLibraryDirectories=[/data/app/cl.kitratech.kitracompanion-86ZcHOAeuYsHtMXNf4Zy9w==/lib/arm64, /data/app/cl.kitratech.kitracompanion-86ZcHOAeuYsHtMXNf4Zy9w==/base.apk!/lib/arm64-v8a, /system/lib64]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
This is a well known issue before version 71, but, in this case, Guava is not listed as Dependency in Nuget. It should be nice to add it as Dependency in the next update.
Also, note that neither v27.1.0.1 nor v27.1.0.2 worked for me (both threw me the same exception as if I didn't install Guava)
thank for the update @JPZV
Also, feel free to close this issue as the main problem (opencensus) was fixed correctly. I will not close it yet because I don't know if you want to use this for a reference about Guava.
@JPZV Thanks for info.
Added dependency. Must tag and wait Azure builds. So, expect fix tomorrow
@JPZV @xamarindevelopervietnam @akamud @guillermo-gerard
The issue should be fixed in version 71.20190927
Packages:
- Xamarin.Firebase.Firestore 71.1705.1
- Xamarin.GooglePlayServices.Games.71.1700.1
Please update your packages and provide us feedback here (or even close the issue if issue is fixed)
Thanks
I didn't see this release version on Nuget Managing Windows
@xamarindevelopervietnam
Now?
@JPZV @xamarindevelopervietnam
Xamarin.Firebase.Firestore.71.1705.2.nupkg pushed
https://www.nuget.org/packages/Xamarin.Firebase.Firestore/71.1705.2
Closing this one. Please open new issue.
Most helpful comment
@akamud @guillermo-gerard @xamarindevelopervietnam @JPZV
TL;DR: I'm actively working on this issue!
Details:
new versions of firebase have dependencies on newer versions of gRPC (Xamarin.Google.Grpc nugets) which introduced new dependencies (
io.opencensusandgrpc-context).I finished binding OpenCensus
https://www.nuget.org/packages/Xamarin.Io.OpenCensus.OpenCensusApi/
https://www.nuget.org/packages/Xamarin.Io.OpenCensus.OpenCensusContribGrpcMetrics/
but grpc-context is not trivial (tons of errors I'm working through)
I beg for your patience.