Android Studio版本升级后的问题 gradle降级、jdk升级

Cannot use @TaskAction annotation on method IncrementalTask.taskAction$gradle_core() because interface org.gradle.api.tasks.incremental.IncrementalTaskInputs is not a valid parameter to an action method.

复制代码
修改下面两处地方分别为7.0.3、7.3.3


Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.

java 复制代码
An exception occurred applying plugin request [id: 'com.android.application']
> Failed to apply plugin 'com.android.internal.application'.
   > Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
     You can try some of the following options:
       - changing the IDE settings.
       - changing the JAVA_HOME environment variable.
       - changing `org.gradle.java.home` in `gradle.properties`.

Can't determine type for tag '<macro name="m3_comp_switch_disabled_selected_handle_color">

AGPBI: {"kind":"error","text":"Can't determine type for tag '<macro name="m3_comp_switch_disabled_selected_handle_color">?attr/colorSurface'","sources":{"file":"/Users/fausto/.gradle/caches/transforms-3/4948d05d0ff6027d2e3c9f4a6010103b/transformed/material-1.7.0-alpha02/res/values/values.xml"},"tool":"Resource and asset merger"}

降级 androidx.appcompat:appcompat

降级 com.google.android.material:material

为以下版本

java 复制代码
    implementation 'androidx.appcompat:appcompat:1.4.1'
    implementation 'com.google.android.material:material:1.6.0'
相关推荐
mmsx23 分钟前
Android 防二次打包第一道锁:签名校验与完整性校验
android·kotlin
mmsx23 分钟前
Android 混淆不等于安全:二次打包链路完整走一遍
android·kotlin
小宋10212 小时前
Agent轨迹级评测实战:工具选择、预算超限与回归门禁
android·网络·人工智能·回归
小李不困还能学3 小时前
VSCode远程开发免密码登录
ide·vscode·编辑器
墨天梦4 小时前
D05_ViewModel与单向数据流
android·kotlin
蒸鱼Yuzheng5 小时前
Android 构建可复现性:APK 指纹、文件级差异与供应链审计
android·apk·devops·软件供应链·可复现构建
墨天梦8 小时前
D03_Compose列表与稳定身份
android·gitee·kotlin
萌新杰少8 小时前
Kuikly股票查看软件开发体验——SaiRen
android·kotlin·客户端
vilya8 小时前
把 Python 塞进 APK:Chaquopy 打包实践
android·python
用户92817267390168 小时前
Android Compose版本的AI组件库来了。
android·kotlin