android - Gradle 文件中存在问题(下面的错误消息)?
问题描述
错误信息-
在 DefaultConfig_Decorated{name=main, dimension=null, minSdkVersion=DefaultApiVersion{mApiLevel=19, mCodename='null'}, targetSdkVersion=DefaultApiVersion{ mApiLevel=25,mCodename='null'},renderscriptTargetApi=null,renderscriptSupportModeEnabled=null,renderscriptSupportModeBlasEnabled=null,renderscriptNdkModeEnabled=null,versionCode=1,versionName=1.0,applicationId=com.vpaliy.loginconcept,testApplicationId=null,testInstrumentationRunner=android .support.test.runner.AndroidJUnitRunner, testInstrumentationRunnerArguments={}, testHandleProfiling=null, testFunctionalTest=null, signingConfig=null, resConfig=null, mBuildConfigFields={}, mResValues={}, mProguardFiles=[],com.android.build.gradle.internal.dsl.DefaultConfig 类型的 mConsumerProguardFiles=[]、mManifestPlaceholders={}、mWearAppUnbundled=null}。
这里是 build.gradle(module.app)
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
applicationId "com.vpaliy.loginconcept"
minSdkVersion 19
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner
"android.support.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
jackOptions {
enabled true
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'),
'proguard-rules.pro'
}
}
}
dependencies {
compile 'com.jakewharton:butterknife:8.5.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.5.1'
compile 'com.andkulikov:transitionseverywhere:1.7.4'
compile 'com.android.support:design:25.3.1'
compile 'com.github.bumptech.glide:glide:3.7.0'
compile 'com.android.support:recyclerview-v7:25.3.1'
compile'net.yslibrary
.keyboardvisibilityevent:keyboardvisibilityevent:2.1.0'
compile 'com.github.bumptech.glide:glide:3.7.0'
compile 'com.github.Q42:AndroidScrollingImageView:1.2'
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
}
解决方案
按照指出的步骤 - 1.// 删除此块。
jackOptions {
enabled true
2.//在 gradle.properties 文件中添加这个块。
android.enableDesugar=true
推荐阅读
- python - 为什么 Pandas Multiindex Merge 会出现 KeyError?
- csv - 提取除第一个唯一列之外的第二列
- visual-studio - TFS | 无法将源项目的文件组织到多个新文件夹中
- asp.net-mvc - 返回任何类型的 DbSet 的方法
- php - 如何在php静态函数中传递全局变量
- c# - 在 ListView 中,如何根据我点击的列表项打开不同的 URL?
- sabre - Sabre StructureFareRules 格式基础不可用错误
- kotlin - 我的游戏自定义输入适配器没有运行渲染系统
- wordpress - 在店面中的类别名称下方添加额外的小部件区域
- jquery - Jquery方法无法获取特定键的值