Android Studio : 407 Proxy Authentication Required

微笑、不失礼 提交于 2019-12-23 22:24:51

问题


I have installed Android Studio Preview version since the stable IDE version does not support the JetPack that is being used in my application.

But I am facing proxy issue while syncing the project,

ERROR: Could not GET 'https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.2.1/gradle-3.2.1.pom'. Received status code 407 from server: Proxy Authentication Required Enable Gradle 'offline mode' and sync project

I have set proxy using both from Android studio settings and gradle.properties file,

gradle.properties

systemProp.http.proxyPort=xxxx
systemProp.http.proxyUser=xxxxx
systemProp.http.proxyPassword=xxxxx
org.gradle.jvmargs=-Xmx1536m
systemProp.https.proxyPassword=xxxxx
systemProp.https.proxyHost=xxxxx
systemProp.http.proxyHost=xxxxx
systemProp.https.proxyPort=xxxxx
systemProp.https.proxyUser=xxxxx

Still project sync gives the same error. Any solutions?

Studio Version : Android Studio 3.3 Beta 4


回答1:


Finally I found a solution.

There is a gradle.properties file under .gradle of home directory ~/.gradle/gradle.properties

where you need to enter your proxy password manually.

systemProp.http.proxyPassword=xxxxx
systemProp.http.proxyHost=xxxxx
systemProp.https.proxyPort=xxxx
systemProp.https.proxyUser=xxxxx
systemProp.https.proxyHost=xxxxx
systemProp.https.proxyPassword=xxxxx
systemProp.http.proxyPort=xxxx
systemProp.http.proxyUser=xxxxx


来源:https://stackoverflow.com/questions/53456614/android-studio-407-proxy-authentication-required

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!