LoginSignup
0
0

More than 5 years have passed since last update.

/Users/user/.gradle/を消した時にビルドが通らない

Posted at

原因

Charles起動してたから…

環境

Mac OS X ElCapitan 10.11.1
Android Studio 1.4、2.0、2.1で全部動かなくなった

事象

http://qiita.com/u_one/items/48a5ed73340974d6dbc3
上記参考に/Users/user/.gradle/を消した時にjcenter等に通信が行かなくなった
下記ビルドしようとした時のログ

* What went wrong:
A problem occurred configuring project ':app'.
> Could not resolve all dependencies for configuration ':app:_debugCompile'.
   > Could not resolve com.squareup.okhttp:okhttp:2.7.0.
     Required by:
         TestProjectAndroid:app:unspecified
      > Could not resolve com.squareup.okhttp:okhttp:2.7.0.
         > Could not get resource 'https://jcenter.bintray.com/com/squareup/okhttp/okhttp/2.7.0/okhttp-2.7.0.pom'.
            > Could not GET 'https://jcenter.bintray.com/com/squareup/okhttp/okhttp/2.7.0/okhttp-2.7.0.pom'.
               > peer not authenticated
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

peer not authenticatedと言われてるのでSSLエラーらしい…下記コマンドでSSL確かめてみるとATSにひっかかってるっぽい

nscurl --ats-diagnostics --verbose https://jcenter.bintray.com/

nscurl --ats-diagnosticsでATS検証したらCharles挟んでるとエラー出ました
Charles落としたら全部PASSになってうまく行きました
.gradleつくるのにいろいろダウンロードしてきたらCharles起動してても大丈夫みたいです
nscurl --ats-diagnosticsはコマンドなのでCharlesの証明書挟むとエラーが出たけど、システムにインストールしたらそんなことないかも?未検証

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0