Skip to content
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

StringIndexOutOfBoundsException when converting javadoc #793

Open
testforstephen opened this issue Sep 4, 2024 · 1 comment
Open

StringIndexOutOfBoundsException when converting javadoc #793

testforstephen opened this issue Sep 4, 2024 · 1 comment

Comments

@testforstephen
Copy link

!ENTRY org.eclipse.jdt.core 4 0 2024-09-04 15:23:40.378
!MESSAGE Failed to convert Javadoc
!STACK 0
java.lang.StringIndexOutOfBoundsException: Range [30856, 30856) out of bounds for length 23933
	at java.base/jdk.internal.util.Preconditions$1.apply(Preconditions.java:55)
	at java.base/jdk.internal.util.Preconditions$1.apply(Preconditions.java:52)
	at java.base/jdk.internal.util.Preconditions$4.apply(Preconditions.java:213)
	at java.base/jdk.internal.util.Preconditions$4.apply(Preconditions.java:210)
	at java.base/jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:98)
	at java.base/jdk.internal.util.Preconditions.outOfBoundsCheckFromToIndex(Preconditions.java:112)
	at java.base/jdk.internal.util.Preconditions.checkFromToIndex(Preconditions.java:349)
	at java.base/java.lang.String.checkBoundsBeginEnd(String.java:4963)
	at java.base/java.lang.String.substring(String.java:2925)
	at org.eclipse.jdt.core.dom.JavacConverter.removeSurroundingWhitespaceFromRange(JavacConverter.java:2683)
	at org.eclipse.jdt.core.dom.JavacConverter.commonSettings(JavacConverter.java:429)
	at org.eclipse.jdt.core.dom.JavacConverter.commonSettings(JavacConverter.java:396)
	at org.eclipse.jdt.core.dom.JavacConverter.convertToType(JavacConverter.java:2748)
	at org.eclipse.jdt.core.dom.JavadocConverter.toMethodRefParam(JavadocConverter.java:761)
	at org.eclipse.jdt.core.dom.JavadocConverter.convertMemberReferenceWithParens(JavadocConverter.java:644)
	at org.eclipse.jdt.core.dom.JavadocConverter.convertElement(JavadocConverter.java:569)
	at org.eclipse.jdt.core.dom.JavadocConverter.convertElementCombiningNodes(JavadocConverter.java:531)
	at org.eclipse.jdt.core.dom.JavadocConverter.convertBlockTag(JavadocConverter.java:244)
	at org.eclipse.jdt.core.dom.JavadocConverter.convertElement(JavadocConverter.java:577)
	at org.eclipse.jdt.core.dom.JavadocConverter.convertElementCombiningNodes(JavadocConverter.java:531)
	at org.eclipse.jdt.core.dom.JavadocConverter.convertJavadoc(JavadocConverter.java:151)
	at org.eclipse.jdt.core.dom.JavacConverter.convert(JavacConverter.java:3239)
	at org.eclipse.jdt.core.dom.JavacConverter.setJavadocForNode(JavacConverter.java:1161)
	at org.eclipse.jdt.core.dom.JavacConverter.commonSettings(JavacConverter.java:432)
	at org.eclipse.jdt.core.dom.JavacConverter.commonSettings(JavacConverter.java:396)
	at org.eclipse.jdt.core.dom.JavacConverter.convertFieldDeclaration(JavacConverter.java:1117)
	at org.eclipse.jdt.core.dom.JavacConverter.convertBodyDeclaration(JavacConverter.java:751)
	at org.eclipse.jdt.core.dom.JavacConverter.convertClassDecl(JavacConverter.java:602)
	at org.eclipse.jdt.core.dom.JavacConverter.convertClassDecl(JavacConverter.java:531)
	at org.eclipse.jdt.core.dom.JavacConverter.convertBodyDeclaration(JavacConverter.java:748)
	at org.eclipse.jdt.core.dom.JavacConverter.lambda$populateCompilationUnit$2(JavacConverter.java:186)
	at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:215)
	at java.base/java.util.Iterator.forEachRemaining(Iterator.java:133)
	at java.base/java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1939)
	at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:570)
	at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:560)
	at java.base/java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151)
	at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174)
	at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:265)
	at java.base/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:636)
	at org.eclipse.jdt.core.dom.JavacConverter.populateCompilationUnit(JavacConverter.java:188)
	at org.eclipse.jdt.core.dom.JavacCompilationUnitResolver.parse(JavacCompilationUnitResolver.java:630)
	at org.eclipse.jdt.core.dom.JavacCompilationUnitResolver.toCompilationUnit(JavacCompilationUnitResolver.java:458)
	at org.eclipse.jdt.core.dom.ASTParser.internalCreateASTCached(ASTParser.java:1263)
	at org.eclipse.jdt.core.dom.ASTParser.lambda$0(ASTParser.java:1142)
	at org.eclipse.jdt.internal.core.JavaModelManager.cacheZipFiles(JavaModelManager.java:5770)
	at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1142)
	at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:882)
	at org.eclipse.jdt.internal.core.CompilationUnit.buildStructure(CompilationUnit.java:219)
	at org.eclipse.jdt.internal.core.Openable.generateInfos(Openable.java:245)
	at org.eclipse.jdt.internal.core.JavaElement.openWhenClosed(JavaElement.java:585)
	at org.eclipse.jdt.internal.core.JavaElement.getElementInfo(JavaElement.java:308)
	at org.eclipse.jdt.internal.core.JavaElement.getElementInfo(JavaElement.java:294)
	at org.eclipse.jdt.internal.core.Openable.getBuffer(Openable.java:275)
	at org.eclipse.jdt.ls.core.internal.handlers.WorkspaceDiagnosticsHandler.visit(WorkspaceDiagnosticsHandler.java:189)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:77)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:87)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:87)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:87)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:87)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:87)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:87)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:87)
	at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:61)
	at org.eclipse.jdt.ls.core.internal.handlers.WorkspaceDiagnosticsHandler.resourceChanged(WorkspaceDiagnosticsHandler.java:113)
	at org.eclipse.core.internal.events.NotificationManager$1.run(NotificationManager.java:321)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:47)
	at org.eclipse.core.internal.events.NotificationManager.notify(NotificationManager.java:311)
	at org.eclipse.core.internal.events.NotificationManager.broadcastChanges(NotificationManager.java:174)
	at org.eclipse.core.internal.resources.Workspace.broadcastPostChange(Workspace.java:459)
	at org.eclipse.core.internal.resources.Workspace.endOperation(Workspace.java:1587)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2465)
	at org.eclipse.core.internal.events.NotificationManager$NotifyJob.run(NotificationManager.java:60)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)

The sample project is https://github.com/mgarin/weblaf.git

@mickaelistria
Copy link

Is this still happening?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants