Android Studio:Gradle 同步失败:无法 HEAD '...'.从

Android Studio: Gradle sync failed: Could not HEAD #39;...#39;. Received status code 502 from server: Bad Gateway(Android Studio:Gradle 同步失败:无法 HEAD ....从服务器收到状态码 502:Bad Gateway)
本文介绍了Android Studio:Gradle 同步失败:无法 HEAD '...'.从服务器收到状态码 502:Bad Gateway的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的项目中将 Android Studio 更新到最新版本 (3.1) 和 gradle 版本后,我收到一个错误(链接总是不同):

After update Android Studio to latest version (3.1) and gradle version in my project I get an error (the link is always different):

12:54   Gradle sync started

12:56   Gradle sync failed: Could not HEAD 'https://jcenter.bintray.com/com/android/tools/analytics-library/shared/26.1.0/shared-26.1.0.jar'. Received status code 502 from server: Bad Gateway             Consult IDE log for more details (Help | Show Log) (1m 56s 602ms)

12:56   Gradle sync started

12:57   Gradle sync failed: Could not HEAD 'https://jcenter.bintray.com/org/codehaus/mojo/animal-sniffer-parent/1.14/animal-sniffer-parent-1.14.pom'. Received status code 502 from server: Bad Gateway             Consult IDE log for more details (Help | Show Log) (1m 4s 266ms)

12:58   Gradle sync started

12:59   Gradle sync failed: Could not HEAD 'https://jcenter.bintray.com/com/sun/activation/all/1.2.0/all-1.2.0.pom'. Received status code 502 from server: Bad Gateway          Consult IDE log for more details (Help | Show Log) (1m 29s 985ms)

13:01   Gradle sync started

13:02   Gradle sync failed: Could not HEAD 'https://jcenter.bintray.com/com/sun/activation/javax.activation/1.2.0/javax.activation-1.2.0.pom'. Received status code 502 from server: Bad Gateway            Consult IDE log for more details (Help | Show Log) (4s 976ms)

Android Studio 版本:

Android Studio version:

Android Studio 3.1
Build #AI-173.4670197, built on March 22, 2018
JRE: 1.8.0_152-release-1024-b02 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Windows 10 10.0

我已经尝试过干净的重建和更新 gradle,重新启动 Android Studio 和 PC,但没有成功.有什么想法吗?

I already tried clean rebuild and update gradle, restart Android Studio and PC, but without success. Any ideas?

PS:我当然有互联网.此外,如果您在浏览器中打开链接 - 文件会被下载.

PS: of course I have internet. Also, if you open a link in the browser - the file is downloaded.

推荐答案

jcenter目前有问题,请查看http://status.bintray.com/

jcenter is having issues at the moment, please check http://status.bintray.com/

这篇关于Android Studio:Gradle 同步失败:无法 HEAD '...'.从服务器收到状态码 502:Bad Gateway的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

How to target newer versions in .gitlab-ci.yml using auto devops (java 11 instead of 8 and Android 31 instead of 29)(如何在.gitlab-ci.yml中使用自动开发工具(Java 11而不是8,Android 31而不是29)瞄准较新的版本)
Android + coreLibraryDesugaring: which Java 11 APIs can I expect to work?(Android+core LibraryDesugering:我可以期待哪些Java 11API能够工作?)
How to render something in an if statement React Native(如何在If语句中呈现某些内容Reaction Native)
How can I sync two flatList scroll position in react native(如何在本机Reaction中同步两个平面列表滚动位置)
Using Firebase Firestore in offline only mode(在仅脱机模式下使用Firebase FiRestore)
Crash on Google Play Pre-Launch Report: java.lang.NoSuchMethodError(Google Play发布前崩溃报告:java.lang.NoSuchMethodError)