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
The method builder() is undefined for the type xxx #3733
There seem to be several issues related (or unrelated) to the Javadoc comments of the @Builder class in the latest Lombok 1.18.34. (issue 1, issue 2)
The version of Lombok bundled in this extension is fromhttps://projectlombok.org/lombok-edge.jar, which currently delivers the same binary as Lombok 1.18.34, thereby affecting this extension.
Temporary solutions I discovered:
Downgrade this extension to v1.32.0
Or use the lombok/lombok-1.18.33.jar bundled in v1.32.0
Overwrite the jar file in the same path of the current version, or build and install the .vsix file yourself
Steps to overwrite
Windows PowerShell environment:
# Get and extract vscode-java v1.32.0 binarycurl.exe-LO "https://github.com/redhat-developer/vscode-java/releases/download/v1.32.0/vscode-java-1.32.0-220.vsix"Rename-Item"vscode-java-1.32.0-220.vsix""vscode-java-1.32.0-220.vsix.zip"Expand-Archive-Path ".\vscode-java-1.32.0-220.vsix.zip"-DestinationPath ".\temp_ext"# Copy .jar fileCopy-Item"temp_ext/extension/lombok/lombok-1.18.33.jar""$env:userprofile/.vscode/extensions/redhat.java-1.33.0-win32-x64/lombok/lombok-1.18.33.jar"# Remove downloaded filesRemove-Item-Recurse -Path "temp_ext","vscode-java-1.32.0-220.vsix.zip"
Linux-like environment:
# Get and extract vscode-java v1.32.0 binary
curl -LO https://github.com/redhat-developer/vscode-java/releases/download/v1.32.0/vscode-java-1.32.0-220.vsix
# or wget:# wget https://github.com/redhat-developer/vscode-java/releases/download/v1.32.0/vscode-java-1.32.0-220.vsix
unzip -d temp_ext/ vscode-java-1.32.0-220.vsix
# Copy .jar file# Replace .vscode with .vscode-server if you're in remote environment (like wsl, docker or ssh)
cp temp_ext/extension/lombok/lombok-1.18.33.jar /home/$(whoami)/.vscode/extensions/redhat.java-1.33.0*/lombok/lombok-1.18.33.jar
# Remove downloaded files
rm -rf /tmp/temp_ext vscode-java-1.32.0-220.vsix
Lombok has merged a fix as of a few days ago (see projectlombok/lombok#3726), but they have not done a release yet. So I assume that will have to happen first so that an updated version of Lombok can be bundled with the extension.
(the 1.18.33 label we give is wrong, but it's definitely the latest), we're using the latest lombok edge release, which is from 2024-10-18. That definitely should have the fix. If it doesn't work then the problem was never fixed by the PR.
With the currently used Lombok v1.18.34 this is still an issue. Updating to v1.18.36 should fix it (relevant commit: projectlombok/lombok@1ac3950). At least it did so for the Eclipse IDE.
Activity
heguro commentedon Aug 2, 2024
There seem to be several issues related (or unrelated) to the Javadoc comments of the
@Builderclass in the latest Lombok 1.18.34. (issue 1, issue 2)The version of Lombok bundled in this extension is from
https://projectlombok.org/lombok-edge.jar, which currently delivers the same binary as Lombok 1.18.34, thereby affecting this extension.Temporary solutions I discovered:
lombok/lombok-1.18.33.jarbundled in v1.32.0.vsixfile yourselfSteps to overwrite
Windows PowerShell environment:
Linux-like environment:
[-]The method builder() is undefined for tye type xxx[/-][+]The method builder() is undefined for the type xxx[/+]hoomoli commentedon Aug 3, 2024
@heguro
Lombokversion is1.18.12in my demo project.Before this extension v1.33.0, it was working fine.
hoomoli commentedon Aug 5, 2024
iwangbowen commentedon Aug 16, 2024
Is it fixed in the latest version
foxpluto commentedon Sep 1, 2024
Which version are you referring? I have the Language Support for Java(TM) by Red Hat v1.35.202408 and the bug is still there.
iwangbowen commentedon Sep 15, 2024
when this will be fixed
Kas-tle commentedon Sep 15, 2024
Lombok has merged a fix as of a few days ago (see projectlombok/lombok#3726), but they have not done a release yet. So I assume that will have to happen first so that an updated version of Lombok can be bundled with the extension.
rgrunber commentedon Oct 28, 2024
#3561 (comment) woke me up. Could someone try the vscode-java pre-release and see if the problem is resolved ? According to
vscode-java/gulpfile.js
Line 132 in 0f89a67
NicoFraenzel commentedon Jan 30, 2025
With the currently used Lombok v1.18.34 this is still an issue. Updating to v1.18.36 should fix it (relevant commit: projectlombok/lombok@1ac3950). At least it did so for the Eclipse IDE.