Received status code 409 from server: Conflict

Android studio在拉取git代碼時,build程序中出現了409錯誤:
Could not GET ‘http://github/bmarrdev/android-DecoView-charting/v0.9.6/android-DecoView-charting-v0.9.6.pom’. Received status code 409 from server: Conflict
Disable Gradle ‘offline mode’ and sync project
解決方案
-
找到一篇相關問題博客,并沒有解決問題,拉取專案里寫法和此篇博客相同
https://github.com/jsibbold/zoomage/issues/39 -
猜測網路原因沒有把庫下載好,嘗試切換網路重新拉取代碼,結果還是沒有成功,出現以下錯誤:
Could not resolve all files for configuration ‘:Base:debugCompileClasspath’.
Could not find android-DecoView-charting.jar (com.github.bmarrdev:android-DecoView-charting:v0.9.6).
Searched in the following locations:
https://jitpack.io/com/github/bmarrdev/android-DecoView-charting/v0.9.6/android-DecoView-charting-v0.9.6.jar
Possible solution:
- Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html
- 檢查依賴包里是否有多個地方參考同樣的包,發現有兩處參考,注釋或者刪掉一處,再把參考處(build.gradle(:Base))里的版本號升級到最高版本就解決了,
查找到最高版本為1.2:
https://github.com/bmarrdev/android-DecoView-charting
dependencies {
compile ‘com.github.bmarrdev:android-DecoView-charting:v1.2’
}
最終原因
- 多個地方的dependencies 參考了重復依賴,
- 版本太舊
轉載請註明出處,本文鏈接:https://www.uj5u.com/yidong/316681.html
標籤:其他
上一篇:如何快速上手Jetpack?Jetpack入門到精通再到(網易云)強化實戰,Github已標星80K+,爆了爆了!
