-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improvement: Bump errorprone to 2.11.0 #2069
Conversation
baseline-error-prone/build.gradle
Outdated
check("StrictUnusedVariable", CheckSeverity.OFF) | ||
} | ||
} | ||
|
||
// Incorrectly identifies tests as junit4 usage | ||
tasks.checkJUnitDependencies.enabled = false | ||
tasks.javadoc.enabled = false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have no idea how to pass --add-exports
flags to javadoc in gradle (options are definitely not being respected) and at this point I have given up and disabled javadoc for errorprone.
@@ -42,6 +42,7 @@ allprojects { | |||
tasks.withType(JavaCompile) { | |||
options.compilerArgs += ['-Werror', '-Xlint:deprecation'] | |||
options.errorprone { | |||
enabled = false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this can be reenabled once we release this pr and pick it up - otherwise we fail because of the break
baseline-error-prone/build.gradle
Outdated
'--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED', | ||
'--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED', | ||
'--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED', | ||
'--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we just set this in gradle.properties
? I think it will fix the java doc problem
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does not, I spent couple hours trying to make it work and nothing made sense. Since with toolchains with fork the jvm for compilation add this to gradle.properties doesn't fix compilation
@@ -152,6 +152,10 @@ class BaselineErrorProneRefasterIntegrationTest extends AbstractPluginTest { | |||
when: | |||
buildFile << standardBuildFile | |||
buildFile << ''' | |||
tasks.withType(JavaCompile) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is unnecessary once mockito releases with bumped errorprone
@@ -68,6 +68,9 @@ class BaselineExactDependenciesTest extends AbstractPluginTest { | |||
mavenCentral() | |||
mavenLocal() // for baseline-error-prone | |||
} | |||
tasks.withType(JavaCompile) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is unnecessary once mockito releases with bumped errorprone
I'm seeing the following error in some excavators, would you mind updating
|
I already have - the problem is that you have the rule compiled against 2.10.0 and you try to run it against 2.11.0. What you're seeing is a linking problem - if you'd recompile the method against new errorprone it will be fine since signature is api but not abi compatible |
bc90269
to
0fb8703
Compare
``` ./gradlew classes testClasses -PerrorProneApply=BugPatternNaming ./gradlew format ```
Released 4.82.0 |
Before this PR
After this PR
==COMMIT_MSG==
Upgrade errorprone to 2.11.0
==COMMIT_MSG==
Since we bundle mockito errorprone rules and there was a slight api break in errorprone we need mockito to release their updated rules first mockito/mockito#2553
Possible downsides?