You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] Errorprone compatibility with Lombok JavaDoc checks on JDK 25 #3940
Describe the bug
With JDK 25 EA, Lombok 1.18.40 and ErrorProne, ErrorProne's JavaDoc-related checks fail with Lombok-generated code with errors like
[javac] error-prone version: 2.36.0
[javac] BugPattern: (see stack trace)
[javac] Stack Trace:
[javac] java.lang.AbstractMethodError: Receiver class lombok.javac.Javac$JavadocOps_8$1 does not define or inherit an implementation of the resolved method 'abstract com.sun.tools.javac.parser.Tokens$Comment stripIndent()' of interface com.sun.tools.javac.parser.Tokens$Comment.
[javac] at jdk.compiler/com.sun.tools.javac.parser.DocCommentParser.<init>(DocCommentParser.java:168)
[javac] at jdk.compiler/com.sun.tools.javac.parser.DocCommentParser.<init>(DocCommentParser.java:146)
[javac] at jdk.compiler/com.sun.tools.javac.api.JavacTrees.getDocCommentTree(JavacTrees.java:1132)
[javac] at jdk.compiler/com.sun.tools.javac.parser.LazyDocCommentTable.getCommentTree(LazyDocCommentTable.java:101)
[javac] at jdk.compiler/com.sun.tools.javac.api.JavacTrees.getDocCommentTree(JavacTrees.java:757)
[javac] at com.google.errorprone.bugpatterns.javadoc.Utils.getDocCommentTree(Utils.java:132)
[javac] at com.google.errorprone.bugpatterns.javadoc.Utils.getDocTreePath(Utils.java:124)
[javac] at com.google.errorprone.bugpatterns.javadoc.InvalidBlockTag.matchVariable(InvalidBlockTag.java:93)
I'm uncertain if this should be filed as an issue against Lombok, ErrorProne, or just considered an unfortunate incompatibility.
I've observed this with the following ErrorProne checks:
AlmostJavadoc
EscapedEntity
InheritDoc
InvalidBlockTag
InvalidInlineTag
InvalidLink
MalformedInlineTag
To Reproduce
I haven't attempted to create a minimal reproducer. I am opening this issue first to discuss what you think of this incompatibility with ErrorProne and JDK 25 in principle. I also haven't filed an issue against ErrorProne. If you think it is more appropriate to fix in ErrorProne, I can open a ticket with that project instead.
Expected behavior
Maybe the Lombok-generated JavadocOps_8 can implement abstract com.sun.tools.javac.parser.Tokens$Comment stripIndent() to prevent this issue?
Version info (please complete the following information):
Lombok version (1.18.40)
Platform JDK 25 EA
Additional context
I'm opening this issue primarily to discuss it before taking further action on it.
Reacted by awa-xima, Simon Planinschek and Thomas Sapelza
changed the title [-][BUG] Errorprone compatibility with Lombok on JDK 25[/-][+][BUG] Errorprone compatibility with Lombok JavaDoc checks on JDK 25[/+]on Sep 30, 2025
I've changed the title of this issue to capture that it was specifically about the JavaDoc-related checks with JDK25 and not a general issue about Lombok + Error prone + JDK 25 compatibility.
import java.util.Set;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
@RequiredArgsConstructor
@Getter
public enum MyType {
FOO("foo", Set.of("a", "b", "c")),
ZOO("zoo", Set.of("a", "b", "c"));
private final String code;
/**
* Set of required fields that must be present in the somewhere.
*/
private final Set<String> requiredFields;
}
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.14.1:compile (default-compile) on project thymeleaf-bank-application: Compilation failure: Compilation failure:
variable bankService not initialized in the default constructor
Activity
asheldon commentedon Sep 15, 2025
This appears adequate to prevent Error Prone from crashing.
Rawi01 commentedon Sep 16, 2025
@asheldon Thanks for the report and for a diff to fix the issue. I hope I can add a test case to catch it earlier next time.
[fixes projectlombok#3940] Add missing stripIndent method
[fixes #3940] Add missing stripIndent method
tarskiandhutch commentedon Sep 23, 2025
Just for the record, I'm seeing ErrorProne error out with Lombok 1.18.38 as well.
Still JDK 25 and ErrorProne 2.36.0.
sergey-morenets commentedon Sep 29, 2025
Still reproduces with Lombok 1.18.42
andrey-borisov-patrianna commentedon Sep 30, 2025
JDK: 25
lombok: 1.18.42
error_prone: 1.18.42
fails as before, same as @sergey-morenets mentioning
[-][BUG] Errorprone compatibility with Lombok on JDK 25[/-][+][BUG] Errorprone compatibility with Lombok JavaDoc checks on JDK 25[/+]asheldon commentedon Sep 30, 2025
I've changed the title of this issue to capture that it was specifically about the JavaDoc-related checks with JDK25 and not a general issue about Lombok + Error prone + JDK 25 compatibility.
[SPARK-53768] Upgrade `lombok` to 1.18.42
rzwitserloot commentedon Oct 2, 2025
It sounds like the next step is a simple and reliable reproduction recipe.
andrey-borisov-patrianna commentedon Oct 2, 2025
JDK: 25
lombok: 1.18.42
error_prone: 1.18.42
Taha-Saifee53 commentedon Jan 24, 2026
Issue with getter and setter with java 25.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.14.1:compile (default-compile) on project thymeleaf-bank-application: Compilation failure: Compilation failure:
variable bankService not initialized in the default constructor