[英]Google Firestore error getting database instance
I am trying to add information to my firebase project using Xamarin.android app but all of a sudden I got this message:我正在尝试使用 Xamarin.android 应用程序向我的 firebase 项目添加信息,但突然间我收到了这条消息:
Java.Lang.NoClassDefFoundError
Message=Failed resolution of: Lcom/google/common/base/Preconditions;
https://paste.ubuntu.com/p/TDNGwSTDTG/ https://paste.ubuntu.com/p/TDNGwSTDTG/
I tried to paste it here as text but it didn't like it:( ^^我试图将它作为文本粘贴到这里,但它不喜欢它:( ^^
I am quite new to Xamarin and Firebase so please don't stone me xD我对 Xamarin 和 Firebase 很陌生,所以请不要用石头砸我 xD
There is a well known conflict beetween Guava
, Xamarin.Firebase
and AndroidX
. Guava
Xamarin.Firebase
和AndroidX
存在众所周知的冲突。
In my case I implemented AndroidX at the end as a new update, so I already had all the logistic configured with Firebase so the fastest, easiest and (for me) the best solution was to stop using AndroidX and start uninstalling all AndroidX package. (Let me tell you, it was a lot.)在我的例子中,我在最后实施了 AndroidX 作为一个新的更新,所以我已经用 Firebase 配置了所有逻辑,所以最快、最简单和(对我来说)最好的解决方案是停止使用 AndroidX 并开始卸载所有 AndroidX package。(让我告诉你,这是很多。)
It wasn't easy because even some of the last updates from Guava or Xamarin.Firebase if I recall correctly, depends on AndroidX so I recommend to check that before you update your Nuget packages.这并不容易,因为如果我没记错的话,即使是 Guava 或 Xamarin.Firebase 的一些最新更新也取决于 AndroidX,因此我建议在更新 Nuget 软件包之前检查一下。
So, long story short, my solution was to stop using AndroidX
Nuget package. At least until this issue got fix.所以,长话短说,我的解决方案是停止使用AndroidX
Nuget package。至少在这个问题得到解决之前。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.