Skip to content

Commit bb9f97a

Browse files
committed
Switch nullaway to enforce nullmarked
1 parent 1cb3810 commit bb9f97a

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

build.gradle

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import net.ltgt.gradle.errorprone.CheckSeverity
2+
13
buildscript {
24
dependencies {
35
classpath 'com.palantir.javaformat:gradle-palantir-java-format:2.83.0'
@@ -75,15 +77,16 @@ subprojects {
7577

7678
tasks.withType(JavaCompile).configureEach {
7779
dependencies {
78-
errorprone "com.uber.nullaway:nullaway:0.12.4"
80+
errorprone "com.uber.nullaway:nullaway:0.13.1"
7981
errorprone "com.google.errorprone:error_prone_core:2.45.0"
8082
}
8183

8284
options.compilerArgs << "-Werror"
8385

8486
options.errorprone {
85-
check("NullAway", net.ltgt.gradle.errorprone.CheckSeverity.OFF)
86-
option("NullAway:AnnotatedPackages", "com.netflix.zuul")
87+
enabled = !name.contains('Jmh') && !name.contains('Test')
88+
check("NullAway", CheckSeverity.ERROR)
89+
option("NullAway:OnlyNullMarked", "true")
8790
errorproneArgs.addAll(
8891
// Uncomment and remove -Werror javac flag to automatically apply fixes for a check.
8992
// N.B: disables all other checks while enabled.

0 commit comments

Comments
 (0)