android - androidX迁移后运行任务问题
问题描述
我在运行项目时遇到了运行任务问题:
:app:preDebugAndroidTestBuild
:app:compileDebugAndroidTestAidl
:app:processDebugManifest
Execute taskAction
:app:compileDebugAndroidTestRenderscript
:app:compileDebugAidl
:app:compileDebugRenderscript
在构建输出中,我收到了以下消息:
Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.1.1/userguide/command_line_interface.html#sec:command_line_warnings
BUILD SUCCESSFUL in 3s
26 actionable tasks: 3 executed, 23 up-to-date
我迁移到 Android X,是否有可能我没有正确执行,所以我遇到了这种麻烦?这些错误有危险吗?我该如何解决这个问题?告诉我您是否需要查看AndroidManifest
或build.gradle
其他代码。提前致谢
编辑
这是 build.gradle:
apply plugin: 'com.android.application'
android {
compileSdkVersion 29
defaultConfig {
applicationId "com.application.packagename"
minSdkVersion 21
targetSdkVersion 29
versionCode 2
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
aaptOptions {
cruncherEnabled = false
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'com.google.android.gms:play-services-ads:18.3.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test:runner:1.2.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
}
构建输出:
Executing tasks: [:app:assembleDebug]
> Task :app:preBuild UP-TO-DATE
> Task :app:preDebugBuild UP-TO-DATE
> Task :app:compileDebugAidl NO-SOURCE
> Task :app:checkDebugManifest UP-TO-DATE
> Task :app:compileDebugRenderscript NO-SOURCE
> Task :app:generateDebugBuildConfig UP-TO-DATE
> Task :app:prepareLintJar UP-TO-DATE
> Task :app:generateDebugSources UP-TO-DATE
> Task :app:javaPreCompileDebug UP-TO-DATE
> Task :app:mainApkListPersistenceDebug UP-TO-DATE
> Task :app:generateDebugResValues UP-TO-DATE
> Task :app:generateDebugResources UP-TO-DATE
> Task :app:mergeDebugResources UP-TO-DATE
> Task :app:createDebugCompatibleScreenManifests UP-TO-DATE
> Task :app:processDebugManifest
> Task :app:processDebugResources
Changing the value for a property with a final value has been deprecated. This will fail with an error in Gradle 6.0.
> Task :app:compileDebugJavaWithJavac UP-TO-DATE
> Task :app:compileDebugSources UP-TO-DATE
> Task :app:mergeDebugShaders UP-TO-DATE
> Task :app:compileDebugShaders UP-TO-DATE
> Task :app:generateDebugAssets UP-TO-DATE
> Task :app:mergeDebugAssets UP-TO-DATE
> Task :app:validateSigningDebug UP-TO-DATE
> Task :app:checkDebugDuplicateClasses UP-TO-DATE
> Task :app:mergeExtDexDebug UP-TO-DATE
> Task :app:mergeLibDexDebug UP-TO-DATE
> Task :app:transformClassesWithDexBuilderForDebug UP-TO-DATE
> Task :app:mergeProjectDexDebug UP-TO-DATE
> Task :app:signingConfigWriterDebug UP-TO-DATE
> Task :app:mergeDebugJniLibFolders UP-TO-DATE
> Task :app:processDebugJavaRes NO-SOURCE
> Task :app:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE
> Task :app:transformResourcesWithMergeJavaResForDebug UP-TO-DATE
> Task :app:packageDebug
> Task :app:assembleDebug
BUILD SUCCESSFUL in 23s
26 actionable tasks: 3 executed, 23 up-to-date
解决方案
推荐阅读
- r - 基于列值的子集行
- python - 在 Python 中的类方法中调用实例方法
- reactjs - 升级到 4.0.0 后 Material UI React Input 损坏
- angular - 谷歌折线图中的蜱虫没有醒来
- javascript - 具有不同图像高度的图像库:消除之间的间隙
- javascript - 使用异步和递归的 JS 程序卡在主进程中
- spring-boot-jpa - 如何将地图集合作为 jpa 查询返回
- google-sheets - 仅返回连接公式的值
- asp.net-mvc - 未捕获的类型错误:无法在 bootstrap.min.js:6 处读取 util.js:68 处未定义的属性“fn”
- python-3.x - Python:使用导入时找不到对类的引用