gpt4 book ai didi

android - module-info.class 的 lint 分析期间出现意外故障

转载 作者:太空宇宙 更新时间:2023-11-03 13:39:53 24 4
gpt4 key购买 nike

有没有其他人看到这个错误:

Errors found:

/home/ligi/git/walleth/app/module-info.class: Error: Unexpected failure during lint analysis of module-info.class (this is a bug in lint or one of the libraries it depends on)

Stack: NullPointerException:InvalidPackageDetector.checkClass(InvalidPackageDetector.java:112)←AsmVisitor.runClassDetectors(AsmVisitor.java:154)←LintDriver.runClassDetectors(LintDriver.kt:1461)←LintDriver.checkClasses(LintDriver.kt:1329)←LintDriver.runFileDetectors(LintDriver.kt:1096)←LintDriver.checkProject(LintDriver.kt:895)←LintDriver.analyze(LintDriver.kt:416)←LintCliClient.run(LintCliClient.java:235)

You can set environment variable LINT_PRINT_STACKTRACE=true to dump a full stacktrace to stdout. [LintError]
Applies to variants: noGethNoFirebaseForFDroidOnlineDebug
/home/ligi/git/walleth/app/module-info.class: Error: Unexpected failure during lint analysis of module-info.class (this is a bug in lint or one of the libraries it depends on)

Stack: NullPointerException:

我只发现这个项目面临同样的问题:

https://github.com/mozilla-mobile/android-components/issues/1730

任何解决方法都会很好

最佳答案

适用于 Android Studio 3.3 及更早版本的 Android 工具阻塞了 Java Platform Module System 所需的 module-info.class 文件(摩根大通)。考虑到 Java 9(第一个随 JPMS 发布的版本)于 2017 年 9 月发布,而 Java 11(第一个带有 JPMS 的 LTS 版本)于 2018 年 9 月发布,大约比 Android Studio 3.3 早 4 个月,这令人难以置信。 Android 问题跟踪器中的相关错误:[lint] InvalidPackage crashes on module-info.class from byte-buddy

因此,解决方法:

  • 将 Android 工具升级到测试版 3.4 或更高版本。我在我的一个项目中测试了 3.4.0-beta05,它运行良好。
  • 将您正在使用的任何库降级到尚不支持 JPMS 的版本(即不包含 module-info.java)。

关于android - module-info.class 的 lint 分析期间出现意外故障,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54749277/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com