我目前在android上遇到了一个错误:http://prntscr.com/lebil3
我显然是个菜鸟。它与Firebase有关,我用一些错误连接到了我的应用程序,但它确实成功地连接了起来。
发布于 2018-11-04 18:42:55
我检查了您提供的链接,您的实现如下所示:
implementation 'com.google.firebase:firebase-database:16.0.1:15.0.0'我认为问题在于最后的15.0.0部分。那不应该在那里。应该是16.0.1。还可以尝试将其添加到应用程序build.gradle中:
implementation 'com.google.firebase:firebase-core:16.0.1'如果这不起作用,请在项目级别的build.gradle文件中检查是否有:
classpath 'com.google.gms:google-services:4.0.1'以及应用程序级别build.gradle底部的插件:
apply plugin: 'com.google.gms.google-services'如果所有这些都不起作用,请查看这份文件 by Firebase如何将Firebase添加到安卓应用程序中。希望这能有所帮助!
发布于 2018-11-04 18:49:30
请在Bluild项目中添加google()
所有项目{存储库{
google()
}}
发布于 2018-11-04 18:47:45
将implementation 'com.google.firebase:firebase-database:16.0.1:15.0.0'更改为implementation 'com.google.firebase:firebase-database:16.0.4'。几天前我也有同样的问题。如果这仍然不起作用,那么将您的其他依赖项与我的依赖项进行比较,并进行相应的调整。
https://stackoverflow.com/questions/53144020
复制相似问题