Repository navigation
Closed
Labels
for: eclipsesomething that is specific for Eclipsestatus: needs-investigationtheme: refactoringtype: bug
Milestone
Description
Used the latest snapshot build for 4.22.1 on Eclipse 2024-03, created a Rest Service sample from the guides, and tried to execute the quick fix to upgrade the boot version to the latest patch via right-click on the problem in the problems view.
Executing the quick fix results in:
java.lang.NullPointerException: Cannot invoke "java.lang.Boolean.booleanValue()" because the return value of "org.eclipse.lsp4j.ChangeAnnotation.getNeedsConfirmation()" is null
at org.eclipse.lsp4e.LSPEclipseUtils.lambda$1(LSPEclipseUtils.java:936)
at java.base/java.util.stream.MatchOps$1MatchSink.accept(MatchOps.java:90)
at java.base/java.util.Spliterators$IteratorSpliterator.tryAdvance(Spliterators.java:1856)
at java.base/java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:129)
at java.base/java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:527)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:513)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
at java.base/java.util.stream.MatchOps$MatchOp.evaluateSequential(MatchOps.java:230)
at java.base/java.util.stream.MatchOps$MatchOp.evaluateSequential(MatchOps.java:196)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.anyMatch(ReferencePipeline.java:632)
at org.eclipse.lsp4e.LSPEclipseUtils.applyWorkspaceEdit(LSPEclipseUtils.java:936)
at org.eclipse.lsp4e.LanguageClientImpl$3.run(LanguageClientImpl.java:127)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
Metadata
Metadata
Assignees
Labels
for: eclipsesomething that is specific for Eclipsestatus: needs-investigationtheme: refactoringtype: bug
Activity
martinlippert commentedon Apr 26, 2024
This seems to break more than just the boot upgrade via quick fix. When I execute the quick fix to remove
@Autowiredfrom a constructor, the same error message appears. This is seriously broken.martinlippert commentedon Apr 26, 2024
I also observed the
Convert @Autowired field into Constructorquick fix to not do anything (also broken), but it does not show up the error above, just does nothing. Maybe the same, maybe a different issue.BoykoAlex commentedon Apr 26, 2024
I saw that only some cases don't work... Need to investigate why that happens. It worked fine for me now but it could be a different rewrite snapshot.
I'm creating a PR for the NPE you've observed above.
BoykoAlex commentedon Apr 26, 2024
Here is the lsp4e PR: eclipse-lsp4e/lsp4e#979
BoykoAlex commentedon Apr 26, 2024
Fixed and the new distro has the lsp4e snapshot with the fix.