如何解決 Android FirebaseUI 中的「無法解析 com.google.android.gms Play-Services-Auth:11.4.0」錯誤?
Resolving "Failed to Resolve Com.google.android.gms Play-Services-Auth:11.4.0" Error
Issue Description
When attempting to write code for Android FirebaseUI - Auth, users may encounter an error "Failed to resolve com.google.android.gms play-services-auth:11.4.0." This error typically arises due to discrepancies in repository configuration or version mismatches.
Solution
To resolve this issue, follow these steps:
1. Add Google Maven Repository to Root-Level build.gradle
Add the following repository to your root-level build.gradle file:
allprojects { repositories { jcenter() maven { url "https://maven.google.com" } } }
Starting from 11.2.0, this maven repository is required.
2. Ensure Consistent Library Versions
Verify that all Firebase and Google Play Services libraries use the same version. In this case, you should use the following versions:
compile 'com.google.firebase:firebase-database:11.0.4' compile 'com.google.firebase:firebase-auth:11.0.4' compile 'com.google.android.gms:play-services-auth:11.4.0'
3. Update Google Play Services Plugin
Upgrade the Google Play Services plugin in your build.gradle file to the latest version (at least 3.3.1):
classpath 'com.google.gms:google-services:4.0.1'
4. Update Libraries to Latest Versions
Update all Firebase and Google Play Services libraries to their latest versions as well.
Note: As of May 2023, Firebase Android SDKs and Google Play Services libraries have independent version numbers.
以上是如何解決 Android FirebaseUI 中的「無法解析 com.google.android.gms Play-Services-Auth:11.4.0」錯誤?的詳細內容。更多資訊請關注PHP中文網其他相關文章!

本文討論了使用Maven和Gradle進行Java項目管理,構建自動化和依賴性解決方案,以比較其方法和優化策略。

本文使用Maven和Gradle之類的工具討論了具有適當的版本控制和依賴關係管理的自定義Java庫(JAR文件)的創建和使用。

本文討論了使用咖啡因和Guava緩存在Java中實施多層緩存以提高應用程序性能。它涵蓋設置,集成和績效優勢,以及配置和驅逐政策管理最佳PRA

本文討論了使用JPA進行對象相關映射,並具有高級功能,例如緩存和懶惰加載。它涵蓋了設置,實體映射和優化性能的最佳實踐,同時突出潛在的陷阱。[159個字符]

Java的類上載涉及使用帶有引導,擴展程序和應用程序類負載器的分層系統加載,鏈接和初始化類。父代授權模型確保首先加載核心類別,從而影響自定義類LOA


熱AI工具

Undresser.AI Undress
人工智慧驅動的應用程序,用於創建逼真的裸體照片

AI Clothes Remover
用於從照片中去除衣服的線上人工智慧工具。

Undress AI Tool
免費脫衣圖片

Clothoff.io
AI脫衣器

AI Hentai Generator
免費產生 AI 無盡。

熱門文章

熱工具

SublimeText3 Mac版
神級程式碼編輯軟體(SublimeText3)

PhpStorm Mac 版本
最新(2018.2.1 )專業的PHP整合開發工具

WebStorm Mac版
好用的JavaScript開發工具

Atom編輯器mac版下載
最受歡迎的的開源編輯器

Dreamweaver Mac版
視覺化網頁開發工具