1
* What went wrong:
A problem occurred configuring project .
> Could not resolve all dependencies for configuration ':mishop2client:GooglePlayDebugCompileClasspath'.
   > Could not resolve com.huawei.hms:network-common:4.0.0.302.
     Required by:
         project :mishop2client
      > Could not resolve com.huawei.hms:network-common:4.0.0.302.
         > Could not get resource 'https://dl.bintray.com/thelasterstar/maven/com/huawei/hms/network-common/4.0.0.302/network-common-4.0.0.302.pom'.
            > Could not HEAD 'https://dl.bintray.com/thelasterstar/maven/com/huawei/hms/network-common/4.0.0.302/network-common-4.0.0.302.pom'. Received status code 504 from server: Gateway Time-out
   > Could not resolve com.huawei.hms:network-common:4.0.0.302.
     Required by:
         project :mishop2client > com.huawei.hms:network-grs:4.0.0.302
      > Could not resolve com.huawei.hms:network-common:4.0.0.302.
         > Could not get resource 'https://dl.bintray.com/thelasterstar/maven/com/huawei/hms/network-common/4.0.0.302/network-common-4.0.0.302.pom'.
            > Could not HEAD 'https://dl.bintray.com/thelasterstar/maven/com/huawei/hms/network-common/4.0.0.302/network-common-4.0.0.302.pom'. Received status code 504 from server: Gateway Time-out

集成 Push Kit 时总是报这个错误。我应该怎么办?

4

2 回答 2

1
  1. 建议您集成最新版本的 Push Kit。目前,最新版本是6.1.0.300

  2. 建议您检查网络配置。出现此错误是因为无法下载Maven。主要原因是网络较差或受限。例如,防火墙不允许您访问华为网站。

于 2021-11-12T02:24:55.363 回答
0

您的日志中maven地址好像不对,请将maven替换到华为的repository,建议将地址放在最后:

repositories {
    google()
    jcenter()    
    maven { url 'https://developer.huawei.com/repo/' }
}
于 2021-11-15T02:12:39.933 回答