Skip to content

Commit 44ea517

Browse files
Copilottrask
andcommitted
Address review feedback for ErrorProne configuration
Co-authored-by: trask <[email protected]>
1 parent 052da6e commit 44ea517

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

buildSrc/src/main/kotlin/ai.errorprone-conventions.gradle.kts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ dependencies {
99
}
1010

1111
val disableErrorProne = properties["disableErrorProne"]?.toString()?.toBoolean() ?: false
12-
val testLatestDeps = gradle.startParameter.projectProperties["testLatestDeps"] == "true"
1312

1413
tasks {
1514
withType<JavaCompile>().configureEach {
@@ -23,8 +22,8 @@ tasks {
2322
disableWarningsInGeneratedCode.set(true)
2423
allDisabledChecksAsWarnings.set(true)
2524

26-
// Ignore warnings for generated and vendored classes
27-
excludedPaths.set(".*/build/generated/.*|.*/concurrentlinkedhashmap/.*")
25+
// Ignore warnings for generated classes
26+
excludedPaths.set(".*/build/generated/.*")
2827

2928
// it's very convenient to debug stuff in the javaagent using System.out.println
3029
// and we don't want to conditionally only check this in CI
@@ -133,13 +132,6 @@ tasks {
133132
// Needs Java 9+
134133
disable("JavaDurationGetSecondsToToSeconds")
135134

136-
if (testLatestDeps) {
137-
// Some latest dep tests are compiled for java 17 although the base version uses an older
138-
// version. Disable rules that suggest using new language features.
139-
disable("StatementSwitchToExpressionSwitch")
140-
disable("PatternMatchingInstanceof")
141-
}
142-
143135
if (name.contains("Jmh") || name.contains("Test")) {
144136
// Allow underscore in test-type method names
145137
disable("MemberName")

0 commit comments

Comments
 (0)