将 Android Studio 更新到 2.3 版本后,我收到警告:
Warning:Using incompatible plugins for the annotation processing: android-apt. This may result in an unexpected behavior.
有什么解决办法吗?我的应用停止工作...
最佳答案
您的应用级 gradle 依赖项应包括(根据黄油刀网站说明):
compile 'com.jakewharton:butterknife:8.8.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.8.1'
您可以删除该行:
apply plugin: 'com.neenbedankt.android-apt'
注解处理在 Android Gradle 插件(2.2 及更高版本)中可用,因此如果使用此版本的 gradle 或更高版本,现在无需再使用上述插件。
如果您想知道如何关闭和打开注释处理,并且设置在:
设置 > 构建、执行、部署 > 编译器 > 注释处理器
关于Android Studio 警告 : Using incompatible plugins for the annotation processing,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42632662/