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

bug: Side effect not allowed: INVOKE_LATER #1538

Open
Nopik opened this issue May 17, 2024 · 0 comments
Open

bug: Side effect not allowed: INVOKE_LATER #1538

Nopik opened this issue May 17, 2024 · 0 comments
Labels
bug Something isn't working clients/jetbrains

Comments

@Nopik
Copy link

Nopik commented May 17, 2024

Cody Version

5.5.10

IDE Information

latest idea

Describe the bug

crash

Expected behavior

no crash

Additional context

Stacktrace:

CompositeException (2 nested):
------------------------------
[1]: com.intellij.model.SideEffectGuard$SideEffectNotAllowedException: Side effect not allowed: INVOKE_LATER
 at com.intellij.model.SideEffectGuard$Companion.checkSideEffectAllowed(SideEffectGuard.kt:21)
 at com.intellij.model.SideEffectGuard.checkSideEffectAllowed(SideEffectGuard.kt)
 at com.intellij.openapi.application.impl.LaterInvocator.invokeLater(LaterInvocator.java:79)
 at com.intellij.openapi.application.impl.ApplicationImpl.invokeLater(ApplicationImpl.java:290)
 at com.intellij.openapi.application.impl.ApplicationImpl.invokeLater(ApplicationImpl.java:274)
 at com.sourcegraph.cody.listeners.CodyDocumentListener.documentChangedNonBulk(CodyDocumentListener.kt:80)
 at com.intellij.openapi.editor.event.BulkAwareDocumentListener.documentChanged(BulkAwareDocumentListener.java:21)
 at jdk.internal.reflect.GeneratedMethodAccessor429.invoke(Unknown Source)
 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.base/java.lang.reflect.Method.invoke(Method.java:568)
 at com.intellij.util.EventDispatcher.dispatchVoidMethod(EventDispatcher.java:119)
 at com.intellij.util.EventDispatcher.lambda$createMulticaster$1(EventDispatcher.java:84)
 at jdk.proxy2/jdk.proxy2.$Proxy68.documentChanged(Unknown Source)
 at com.intellij.openapi.editor.impl.DocumentImpl.lambda$changedUpdate$1(DocumentImpl.java:917)
 at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeNonCancelableSection$3(CoreProgressManager.java:269)
 at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:735)
 at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:691)
 at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$computeInNonCancelableSection$4(CoreProgressManager.java:277)
 at com.intellij.openapi.progress.Cancellation.computeInNonCancelableSection(Cancellation.java:57)
 at com.intellij.openapi.progress.impl.CoreProgressManager.computeInNonCancelableSection(CoreProgressManager.java:277)
 at com.intellij.openapi.progress.impl.CoreProgressManager.executeNonCancelableSection(CoreProgressManager.java:268)
 at com.intellij.openapi.editor.impl.DocumentImpl.changedUpdate(DocumentImpl.java:914)
 at com.intellij.openapi.editor.impl.DocumentImpl.updateText(DocumentImpl.java:818)
 at com.intellij.openapi.editor.impl.DocumentImpl.replaceString(DocumentImpl.java:658)
 at com.intellij.openapi.editor.impl.DocumentImpl.replaceString(DocumentImpl.java:595)
 at com.intellij.grazie.ide.inspection.grammar.quickfix.GrazieReplaceTypoQuickFix.applyReplacements(GrazieReplaceTypoQuickFix.kt:199)
 at com.intellij.grazie.ide.inspection.grammar.quickfix.GrazieReplaceTypoQuickFix$ChangeToVariantAction.performFix(GrazieReplaceTypoQuickFix.kt:111)
 at com.intellij.grazie.ide.inspection.grammar.quickfix.GrazieReplaceTypoQuickFix$ChangeToVariantAction$ForPreview.applyFix(GrazieReplaceTypoQuickFix.kt:140)
 at com.intellij.codeInspection.IntentionAndQuickFixAction.invoke(IntentionAndQuickFixAction.java:48)
 at com.intellij.codeInsight.intention.IntentionAction.generatePreview(IntentionAction.java:114)
 at com.intellij.codeInsight.intention.impl.IntentionActionWithTextCaching$MyIntentionAction.generatePreview(IntentionActionWithTextCaching.java:267)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable$invokePreview$1$1$1.invoke(IntentionPreviewComputable.kt:132)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable$invokePreview$1$1$1.invoke(IntentionPreviewComputable.kt:131)
 at com.intellij.model.SideEffectGuard$Companion.computeWithAllowedSideEffectsBlocking(SideEffectGuard.kt:42)
 at com.intellij.model.SideEffectGuard$Companion.computeWithoutSideEffects(SideEffectGuard.kt:27)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable.invokePreview$lambda$2$lambda$1(IntentionPreviewComputable.kt:131)
 at com.intellij.psi.impl.source.PostprocessReformattingAspectImpl.lambda$postponeFormattingInside$2(PostprocessReformattingAspectImpl.java:139)
 at com.intellij.psi.impl.source.PostprocessReformattingAspectImpl.postponeFormattingInside(PostprocessReformattingAspectImpl.java:148)
 at com.intellij.psi.impl.source.PostprocessReformattingAspectImpl.postponeFormattingInside(PostprocessReformattingAspectImpl.java:138)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable.invokePreview$lambda$2(IntentionPreviewComputable.kt:130)
 at com.intellij.codeInsight.intention.preview.IntentionPreviewUtils.previewSession(IntentionPreviewUtils.java:123)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable.invokePreview(IntentionPreviewComputable.kt:129)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable.generatePreview(IntentionPreviewComputable.kt:90)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable.tryCreateDiffContent(IntentionPreviewComputable.kt:66)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable.call(IntentionPreviewComputable.kt:44)
 at com.intellij.codeInsight.intention.impl.preview.IntentionPreviewComputable.call(IntentionPreviewComputable.kt:38)
 at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$OTelMonitor.callWrapped(NonBlockingReadActionImpl.java:851)
 at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$OTelMonitor$MonitoredComputation.call(NonBlockingReadActionImpl.java:883)
 at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$Submission.insideReadAction(NonBlockingReadActionImpl.java:604)
 at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$Submission.lambda$attemptComputation$4(NonBlockingReadActionImpl.java:567)
 at com.intellij.openapi.application.impl.RwLockHolder.tryRunReadAction(RwLockHolder.kt:310)
 at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:958)
 at com.intellij.openapi.progress.util.ProgressIndicatorUtils.lambda$runInReadActionWithWriteActionPriority$0(ProgressIndicatorUtils.java:93)
 at com.intellij.openapi.progress.util.ProgressIndicatorUtilService.runActionAndCancelBeforeWrite(ProgressIndicatorUtilService.java:66)
 at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runActionAndCancelBeforeWrite(ProgressIndicatorUtils.java:155)
 at com.intellij.openapi.progress.uti...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working clients/jetbrains
Projects
None yet
Development

No branches or pull requests

2 participants