Gradle sync failed: Cause: org.gradle.logging.StyledTextOutput$Style Consult IDE log for more details
环境
Android studio 3.0
导入开源中国:
...
dependencies {
//noinspection GradleDependency
classpath 'com.android.tools.build:gradle:2.2.3'
classpath 'com.getkeepsafe.dexcount:dexcount-gradle-plugin:0.3.0'
}
ext {
compileSdkVersion = 25
buildToolsVersion = "25.*.*"
applicationId = "net.oschina.app"
minSdkVersion = 19
targetSdkVersion = 25
versionCode = 417
versionName = "v4.1.7 (1806190800)"
supportVersion = '25.*.*'
}
错误
Gradle sync failed: Cause: org.gradle.logging.StyledTextOutput$Style Consult IDE log for more details (Help | Show Log) (1m 35s 824ms)

原因
gradle , SDK,android studio 三者版本不一致,
android studio buildToolsVersion 最低为26.0.2

解决
调试版本就好了,如:
dependencies {
//noinspection GradleDependency
classpath 'com.android.tools.build:gradle:3.0.0'
classpath 'com.getkeepsafe.dexcount:dexcount-gradle-plugin:0.6.0'
}
ext {
compileSdkVersion = 26
buildToolsVersion = "26.0.2"
applicationId = "net.oschina.app"
minSdkVersion = 19
targetSdkVersion = 26
versionCode = 417
versionName = "v4.1.7 (1806190800)"
supportVersion = '26.0.2'
}
注意检查gradle:
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip
Gradle sync failed: Cause: org.gradle.logging.StyledTextOutput$Style Consult IDE log for more details的更多相关文章
- Gradle sync failed: /Applications/Android Studio.app/Contents/gradle/gradle-2.14.1/lib/plugins/gradle-diagnostics-2.14.1.jar (No such file or directory) Consult IDE log for more details (Help | Sh
上面出现的错误是,我从Android Studio 2.2 升级到2.3后,出现的问题, 找到方法: http://stackoverflow.com/questions/30526613/andro ...
- Android Studio 首坑 Gradle sync failed: Cause: error in opening zip file 的错误
前言 今天安装Android studio 2.3.1时发生了一个错误,安装完成后创建第一个Hello World项目是报错.经过这个百度后,结果没有一个靠谱的.将拆解经过记录一下. 环境: 操作系统 ...
- Gradle sync failed: failed to find Build Tools revision 21.1.2
从github上下载了一个开源项目到Android Studio 出现以下问题: 下午2:56:05 Gradle sync started下午3:00:11 Gradle sync failed: ...
- Gradle sync failed 异常
今天开发过程中出现如下异常 Gradle sync failed: Connection timed out: connect. If you are behind an HTTP proxy, pl ...
- Gradle sync failed: Read timed out
: Gradle sync started : Gradle sync failed: Read timed out Consult IDE log m s ms) 原因是Gradle下载超时 一.下 ...
- AS中加载gradle时出现Gradle sync failed: Could not find com.android.tools.build:gradle.的错误
时间:2019/12/7 这次接着整理加载gradle时出现的错误 出现的错误: Gradle sync failed: Could not find com.android.tools.build: ...
- Android Studio中Gradle sync failed
问题:Android Studio中更新同步Gradle 失败 Gradle sync failed: Could not find com.android.tools.build:gradle:3. ...
- Gradle sync failed: Gradle version 2.2 is required. Current version is 2.10.
Gradle sync failed: Gradle version 2.2 is required. Current version is 2.10. If using the gradle wra ...
- Android Stutio 3.0 - Gradle sync failed
0.Android Studio 权威教程 (url:http://blog.csdn.net/column/details/zsl-androidstudio.html) 1. 项目老是报错: Gr ...
随机推荐
- 973. K Closest Points to Origin
We have a list of points on the plane. Find the K closest points to the origin (0, 0). (Here, the d ...
- jQuery实现ie浏览器兼容placeholder效果
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...
- Three Religions CodeForces - 1149B (字符串,dp)
大意: 给定字符串S, 要求维护三个串, 支持在每个串末尾添加或删除字符, 询问S是否能找到三个不相交的子序列等于三个串. 暴力DP, 若不考虑动态维护的话, 可以直接$O(len^3)$处理出最少需 ...
- 如何在linux上安装使用virt-manager
环境是centos6.5-64位操作系统. 1.准备yum源: 将CentOS6-Base-163.repo 下载到目标主机的/etc/yum.repos.d/目录. cd /etc/yum.repo ...
- Java面试必问
1. 图灵 1.1 聊聊哈希算法与HashMap 1)一个优秀的哈希算法有什么特点? 快速.不可逆.敏感性.低碰撞性 2)自己写一个Hash算法 取模 3)Java中的Hash算法 HashMap,侧 ...
- 洛谷P4220 [WC2018]通道(边分治+虚树)
题面 传送门 题解 代码不就百来行么也不算很长丫 虽然这题随机化贪心就可以过而且速度和正解差不多不过我们还是要好好学正解 前置芝士 边分治 米娜应该都知道点分治是个什么东西,而边分治,顾名思义就是对边 ...
- 省选后CTS/APIO前文化课划水记
目前没有什么明确的目标,所以就叫划水吧. 第一周 4.9 (Tue) 早上 10:00 到学校,然后去仓库找了张桌子,搬到教室,开始自习生活. 拿出"必背古诗文",发现除了< ...
- nginx下重写隐藏index.php文件
location / { root /项目目录/; index index.php; if (-f $request_filename/index.php){ rewrite (.*) $1/inde ...
- TP5.0学习历程(1)
验证码的使用 控制器代码如下: $captcha = new \think\captcha\Captcha(); if (!$captcha->check($data['code ...
- Regini命令的使用和参数讲解
Regini程序操作系统自带的,从XP开始就有,主要是用于修改注册表及注册表权限.我们就从这两方面介绍regini的用法.Regini必须要指定操作脚本,也就是,提前将你要操作的内容写在一个文本文件中 ...