-
Notifications
You must be signed in to change notification settings - Fork 51
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
java.lang.IllegalArgumentException: Wrong offsets: start=540; end=539; document length=539 #737
Comments
There is another stacktrace too that I'm not sure if it's related: java.lang.IllegalStateException: Synchronizer should apply to only a single document, which is the one it was instantiated for
at com.redhat.devtools.intellij.quarkus.lsp4ij.DocumentContentSynchronizer.checkEvent(DocumentContentSynchronizer.java:211)
at com.redhat.devtools.intellij.quarkus.lsp4ij.DocumentContentSynchronizer.beforeDocumentChange(DocumentContentSynchronizer.java:108)
at com.intellij.openapi.editor.impl.DocumentImpl.lambda$beforeChangedUpdate$1(DocumentImpl.java:881)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeNonCancelableSection$3(CoreProgressManager.java:222)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:679)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:635)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$computeInNonCancelableSection$4(CoreProgressManager.java:230)
at com.intellij.openapi.progress.Cancellation.computeInNonCancelableSection(Cancellation.java:99)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeInNonCancelableSection(CoreProgressManager.java:230)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeNonCancelableSection(CoreProgressManager.java:221)
at com.intellij.openapi.editor.impl.DocumentImpl.beforeChangedUpdate(DocumentImpl.java:878)
at com.intellij.openapi.editor.impl.DocumentImpl.updateText(DocumentImpl.java:818)
at com.intellij.openapi.editor.impl.DocumentImpl.replaceString(DocumentImpl.java:664)
at com.intellij.openapi.editor.impl.DocumentImpl.replaceText(DocumentImpl.java:533)
at com.intellij.openapi.fileEditor.impl.FileDocumentManagerImpl$3.run(FileDocumentManagerImpl.java:730)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:980)
at com.intellij.openapi.fileEditor.impl.FileDocumentManagerImpl.lambda$reloadFromDisk$6(FileDocumentManagerImpl.java:716)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:219)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:174)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:164)
at com.intellij.openapi.fileEditor.impl.FileDocumentManagerImpl.reloadFromDisk(FileDocumentManagerImpl.java:716)
at com.intellij.openapi.fileEditor.impl.FileDocumentManagerImpl.contentsChanged(FileDocumentManagerImpl.java:695)
at com.intellij.openapi.fileEditor.impl.FileDocumentManagerImpl$MyAsyncFileListener$1.afterVfsChange(FileDocumentManagerImpl.java:635)
at com.intellij.openapi.vfs.newvfs.AsyncEventSupport.afterVfsChange(AsyncEventSupport.java:133)
at com.intellij.openapi.vfs.newvfs.AsyncEventSupport.processEventsFromRefresh(AsyncEventSupport.java:156)
at com.intellij.openapi.vfs.newvfs.RefreshSessionImpl.fireEventsInWriteAction(RefreshSessionImpl.java:228)
at com.intellij.openapi.vfs.newvfs.RefreshSessionImpl.lambda$fireEvents$1(RefreshSessionImpl.java:209)
at com.intellij.openapi.application.impl.ApplicationImpl.lambda$runEdtProgressWriteAction$6(ApplicationImpl.java:944)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:186)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$13(CoreProgressManager.java:604)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:679)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:635)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:603)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:60)
at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:173)
at com.intellij.openapi.progress.util.PotemkinProgress.runInSwingThread(PotemkinProgress.java:150)
at com.intellij.openapi.application.impl.ApplicationImpl.lambda$runEdtProgressWriteAction$7(ApplicationImpl.java:944)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteActionWithClass(ApplicationImpl.java:968)
at com.intellij.openapi.application.impl.ApplicationImpl.runEdtProgressWriteAction(ApplicationImpl.java:942)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteActionWithNonCancellableProgressInDispatchThread(ApplicationImpl.java:923)
at com.intellij.openapi.vfs.newvfs.RefreshSessionImpl.lambda$fireEvents$2(RefreshSessionImpl.java:204)
at com.intellij.openapi.application.WriteAction.lambda$run$1(WriteAction.java:86)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteActionWithClass(ApplicationImpl.java:968)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:994)
at com.intellij.openapi.application.WriteAction.run(WriteAction.java:85)
at com.intellij.openapi.vfs.newvfs.RefreshSessionImpl.fireEvents(RefreshSessionImpl.java:203)
at com.intellij.openapi.vfs.newvfs.RefreshQueueImpl.lambda$queueSession$2(RefreshQueueImpl.java:103)
at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$Submission.lambda$safeTransferToEdt$6(NonBlockingReadActionImpl.java:633)
at com.intellij.openapi.application.TransactionGuardImpl.runWithWritingAllowed(TransactionGuardImpl.java:209)
at com.intellij.openapi.application.TransactionGuardImpl.access$100(TransactionGuardImpl.java:21)
at com.intellij.openapi.application.TransactionGuardImpl$1.run(TransactionGuardImpl.java:191)
at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:838)
at com.intellij.openapi.application.impl.ApplicationImpl$3.run(ApplicationImpl.java:454)
at com.intellij.openapi.application.impl.FlushQueue.doRun(FlushQueue.java:74)
at com.intellij.openapi.application.impl.FlushQueue.runNextEvent(FlushQueue.java:114)
at com.intellij.openapi.application.impl.FlushQueue.flushNow(FlushQueue.java:36)
at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:779)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:730)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:724)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:749)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:909)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:756)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$5(IdeEventQueue.java:437)
at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:787)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$6(IdeEventQueue.java:436)
at com.intellij.openapi.application.TransactionGuardImpl.performActivity(TransactionGuardImpl.java:105)
at com.intellij.ide.IdeEventQueue.performActivity(IdeEventQueue.java:615)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$7(IdeEventQueue.java:434)
at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:838)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:480)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:207)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:117)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:113)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:105)
at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:92)
Suppressed: java.lang.IllegalStateException: Synchronizer should apply to only a single document, which is the one it was instantiated for
at com.redhat.devtools.intellij.quarkus.lsp4ij.DocumentContentSynchronizer.checkEvent(DocumentContentSynchronizer.java:211)
at com.redhat.devtools.intellij.quarkus.lsp4ij.DocumentContentSynchronizer.documentChanged(DocumentContentSynchronizer.java:81)
at com.intellij.openapi.editor.impl.DocumentImpl.lambda$changedUpdate$2(DocumentImpl.java:922)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeNonCancelableSection$3(CoreProgressManager.java:222)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:679)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:635)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$computeInNonCancelableSection$4(CoreProgressManager.java:230)
at com.intellij.openapi.progress.Cancellation.computeInNonCancelableSection(Cancellation.java:99)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeInNonCancelableSection(CoreProgressManager.java:230)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeNonCancelableSection(CoreProgressManager.java:221)
at com.intellij.openapi.editor.impl.DocumentImpl.changedUpdate(DocumentImpl.java:919)
at com.intellij.openapi.editor.impl.DocumentImpl.updateText(DocumentImpl.java:823)
... 67 more |
I am not sure how to reproduce it as it seems to be triggered in a race condition of some sort |
Which files areyou editing application.properties or Qute html files? |
I don't remember exactly to be honest, but given it happened when browsing the Quarkus Core sources I'd say neither :) |
It seems the problem comes from start > end offset (perhaps it is a bug from MP LS or Qute LS, but without having some usecase it is hard to discover the problem). Anyway, I think IJ LSP client should take care of this problem and it should be aligned from LSP4E which seems to takecare of this problem https://github.com/vladdu/lsp4e/blob/0e31b7f3713c2df18738aa3aea68ef887ec4a64b/org.eclipse.lsp4e/src/org/eclipse/lsp4e/operations/diagnostics/LSPDiagnosticsToMarkers.java#L137 |
document length=539 Fixes redhat-developer#737 Signed-off-by: azerr <[email protected]>
document length=539 Fixes redhat-developer#737 Signed-off-by: azerr <[email protected]>
document length=539 Fixes redhat-developer#737 Signed-off-by: azerr <[email protected]>
(#692 #737) Signed-off-by: azerr <[email protected]>
It is an another issue which is tracked in #752 but I cannot reproduce it, please help me to reproduce it. This issue it is again a problem with editor synchronization with LSP language server fixed in #778 Please install last version of IJ Quarkus which has been published. You should not seen this error (I hope), but please note there is a problem with diagnostic which is not refresh correctly. For the moment you need to type a space to refresh the diagnostic correctly, the issue is tracked in #692 Please reopen the issue if you encounter again the problem. |
related to #764
While having the plugin enabled with the https://github.com/quarkusio/quarkus sources checked out I see the following error:
The text was updated successfully, but these errors were encountered: