还有其他人看到此错误:
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
任何解决方法都很好
答案 0 :(得分:3)
Java Platform Module System(JPMS)所需的module-info.class
文件上的Android Studio 3.3及更早版本的Android工具。考虑到JPMS附带的第一个版本Java 9于2017年9月发布,JPMS附带的第一个LTS版本Java 11于2018年9月发布,大约比Android Studio 3.3早4个月,这让人感到困惑。 Android问题追踪器中的相关错误:[lint] InvalidPackage crashes on module-info.class from byte-buddy
因此,解决方法:
module-info.java
)。 答案 1 :(得分:0)
要忽略此错误,我在lint.xml
中定义了该错误:
<issue id="LintError">
<ignore regexp=".*module-info\.class.*"/>
</issue>
上述变通办法对我不起作用: