Android Studio报错:Supertypes of the following classes cannot be resolved
Android Studio报错:Supertypes of the following classes cannot be resolved
Supertypes of the following classes cannot be resolved. Please make sure you have the required dependencies in the classpath:
class com.xxx, unresolved supertypes: xxx
Adding -Xextended-compiler-checks argument might provide additional information.
解决方案:
1、点击Android Studio右上角的 X 关闭 AS。
2、启动 Android Studio。
3、Android Studio -> File -> Invalidate Caches...
弹出框3项都勾选。
4、然后 Invalidate and Restart
如果一轮不行,重复操作 1~4 步骤,多试几轮就可以了。
Android Studio报错:Inconsistent JVM-target compatibility detected for tasks ‘compileDebugJavaWithJavac-CSDN博客文章浏览阅读717次,点赞18次,收藏18次。【摘要】遇到Kapt任务与Java编译JVM版本不一致报错(1.8 vs 21),需在build.gradle的android模块中添加kotlinOptions{jvmTarget='1.8'}强制统一版本。另提供两个相关开发技巧:1)通过官方文档查询Gradle与AGP版本对应关系;2)迁移.gradle文件夹位置解决系统盘空间问题,需在AndroidStudio设置中更新路径。这些方案涉及版本兼容性配置和开发环境优化。(149字)https://blog.csdn.net/zhangphil/article/details/148700892