安卓开发中遇到的问题

本文详细解析了Error:Nosuchproperty:GradleVersion错误的根源,即IDE版本与Gradle版本不匹配的问题,并提供了调整GradlePlugin与Gradle版本的方法,以确保项目的顺利运行。

问题:Error:No such property: GradleVersion for class: JetGradlePlugin

错误原因:IDE 版本(GradlePlugin)和 Gradle 版本不匹配导致这个错误。
GradlePlugin 版本和 AndroidStudio 版本一致,与 Gradle 版本有一张对应表distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-all.zip改成
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip

这两个必须都要用才能使用 Gradle,而且他们还有一个严格的对应关系。
https://developer.android.google.cn/studio/releases/gradle-plugin.html#

Plugin versionRequired Gradle version
1.0.0 - 1.1.32.2.1 - 2.3
1.2.0 - 1.3.12.2.1 - 2.9
1.5.02.2.1 - 2.13
2.0.0 - 2.1.22.10 - 2.13
2.1.3 - 2.2.32.14.1+
2.3.0+3.3+
3.0.0+4.1+

2018/1/30 Plugin version: 3.0.1 ==> Gradle version: 4.1-all

参考如下:感谢2位博主

https://www.jianshu.com/p/2ca7e87a4afc

https://blog.youkuaiyun.com/mldxs/article/details/86756031

Unable to resolve dependency for ':app@debug/compileClasspath': Could not download crashreport.aar (com.tencent.bugly:crashreport:3.1.0)

Could not download crashreport.aar (com.tencent.bugly:crashreport:3.1.0)
 > Could not get resource 'https://jcenter.bintray.com/com/tencent/bugly/crashreport/3.1.0/crashreport-3.1.0.aar'.
    > Could not GET 'https://jcenter.bintray.com/com/tencent/bugly/crashreport/3.1.0/crashreport-3.1.0.aar'.
          > Remote host closed connection during handshake
                   > SSL peer shut down incorrectly

感谢以上博文作者的经验分享,谢谢!如有不妥的地方,请评论区留言,本人看到会立刻处理。

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值