IllegalArgumentException: Requested element count -1 is less than zero.
rklec opened this issue · 6 comments
STR
I don't know. Was just a strat of WebStorm when already started with another project. Started and, git pull, stopped Angular/test server, i.e did a lot of things and then this happened.
Log
update failed for AnAction(com.github.lppedd.cc.vcs.ClearLocalMessageHistoryAction, id=cc.vcs.clearLocalMessageHistory) with text=Clear Message History
java.lang.IllegalArgumentException: Requested element count -1 is less than zero.
at kotlin.sequences.SequencesKt___SequencesKt.take(_Sequences.kt:557)
at com.github.lppedd.cc.vcs.InternalRecentCommitsService.parseMessage(InternalRecentCommitsService.kt:125)
at com.github.lppedd.cc.vcs.InternalRecentCommitsService.updateCachedTokens(InternalRecentCommitsService.kt:74)
at com.github.lppedd.cc.vcs.InternalRecentCommitsService.<init>(InternalRecentCommitsService.kt:41)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at com.intellij.serviceContainer.ConstructorInjectionKt.instantiateUsingPicoContainer(constructorInjection.kt:52)
at com.intellij.serviceContainer.ComponentManagerImpl.instantiateClassWithConstructorInjection(ComponentManagerImpl.kt:891)
at com.intellij.serviceContainer.ServiceComponentAdapter.createAndInitialize(ServiceComponentAdapter.kt:51)
at com.intellij.serviceContainer.ServiceComponentAdapter.access$createAndInitialize(ServiceComponentAdapter.kt:12)
at com.intellij.serviceContainer.ServiceComponentAdapter$doCreateInstance$1.compute(ServiceComponentAdapter.kt:45)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:683)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:639)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeInNonCancelableSection(CoreProgressManager.java:238)
at com.intellij.serviceContainer.ServiceComponentAdapter.doCreateInstance(ServiceComponentAdapter.kt:44)
at com.intellij.serviceContainer.BaseComponentAdapter.getInstanceUncached(BaseComponentAdapter.kt:119)
at com.intellij.serviceContainer.BaseComponentAdapter.getInstance(BaseComponentAdapter.kt:73)
at com.intellij.serviceContainer.BaseComponentAdapter.getInstance$default(BaseComponentAdapter.kt:66)
at com.intellij.serviceContainer.ComponentManagerImpl.doGetService(ComponentManagerImpl.kt:610)
at com.intellij.serviceContainer.ComponentManagerImpl.getService(ComponentManagerImpl.kt:584)
at com.intellij.openapi.client.ClientAwareComponentManager.getFromSelfOrCurrentSession(ClientAwareComponentManager.kt:37)
at com.intellij.openapi.client.ClientAwareComponentManager.getService(ClientAwareComponentManager.kt:22)
at com.github.lppedd.cc.vcs.ClearLocalMessageHistoryAction.update(ClearLocalMessageHistoryAction.kt:40)
at com.intellij.openapi.actionSystem.ex.ActionUtil.lambda$performDumbAwareUpdate$0(ActionUtil.java:131)
at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareUpdate(ActionUtil.java:145)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.doUpdate(ActionUpdater.java:645)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$updateActionReal$4(ActionUpdater.java:126)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$computeOnEdt$6(ActionUpdater.java:210)
at com.intellij.openapi.progress.ProgressManager.lambda$runProcess$0(ProgressManager.java:58)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:189)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$12(CoreProgressManager.java:608)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:683)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:639)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:607)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:60)
at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:176)
at com.intellij.openapi.progress.ProgressManager.runProcess(ProgressManager.java:58)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$computeOnEdt$7(ActionUpdater.java:208)
at com.intellij.openapi.actionSystem.impl.ActionUpdateEdtExecutor.lambda$computeOnEdt$0(ActionUpdateEdtExecutor.java:45)
at com.intellij.openapi.actionSystem.impl.Utils.lambda$expandActionGroupFastTrack$5(Utils.java:270)
at com.intellij.openapi.actionSystem.impl.Utils.runLoopAndWaitForFuture(Utils.java:595)
at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroupFastTrack(Utils.java:268)
at com.intellij.openapi.actionSystem.impl.ActionToolbarImpl.updateActionsImplFastTrack(ActionToolbarImpl.java:1231)
at com.intellij.openapi.actionSystem.impl.ActionToolbarImpl.updateActionsImpl(ActionToolbarImpl.java:1201)
at com.intellij.openapi.actionSystem.impl.ActionToolbarImpl$1.updateActionsImpl(ActionToolbarImpl.java:201)
at com.intellij.openapi.actionSystem.impl.ToolbarUpdater$MyUpdateRunnable.run(ToolbarUpdater.java:152)
at com.intellij.openapi.actionSystem.impl.ToolbarUpdater.updateActions(ToolbarUpdater.java:68)
at com.intellij.openapi.actionSystem.impl.ActionToolbarImpl.updateActionsImmediately(ActionToolbarImpl.java:1181)
at com.intellij.openapi.actionSystem.impl.ActionToolbarImpl.updateActionsImmediately(ActionToolbarImpl.java:1166)
at com.intellij.openapi.actionSystem.impl.ActionToolbarImpl.addNotify(ActionToolbarImpl.java:257)
at java.desktop/java.awt.Container.addNotify(Container.java:2800)
at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4791)
at java.desktop/java.awt.Container.addImpl(Container.java:1146)
at java.desktop/java.awt.Container.add(Container.java:436)
at com.intellij.openapi.ui.Splitter.setSecondComponent(Splitter.java:692)
at com.intellij.openapi.vcs.changes.ChangesViewManager$ChangesViewToolWindowPanel.updateCommitWorkflow(ChangesViewManager.java:591)
at com.intellij.openapi.vcs.changes.ChangesViewManager.updateCommitWorkflow(ChangesViewManager.java:268)
at com.intellij.openapi.vcs.changes.ChangesViewManager.lambda$new$0(ChangesViewManager.java:117)
at com.intellij.util.messages.impl.MessageBusImpl.invokeMethod(MessageBusImpl.java:639)
at com.intellij.util.messages.impl.MessageBusImpl.invokeListener(MessageBusImpl.java:617)
at com.intellij.util.messages.impl.MessageBusImpl.access$300(MessageBusImpl.java:34)
at com.intellij.util.messages.impl.MessageBusImpl$MessagePublisher.executeOrAddToQueue(MessageBusImpl.java:209)
at com.intellij.util.messages.impl.MessageBusImpl$MessagePublisher.publish(MessageBusImpl.java:191)
at com.intellij.util.messages.impl.MessageBusImpl$MessagePublisher.invoke(MessageBusImpl.java:167)
at com.sun.proxy.$Proxy153.commitModeChanged(Unknown Source)
at com.intellij.vcs.commit.CommitModeManager.updateCommitMode(CommitModeManager.kt:90)
at com.intellij.vcs.commit.CommitModeManager.access$updateCommitMode(CommitModeManager.kt:58)
at com.intellij.vcs.commit.CommitModeManager$MyStartupActivity$runActivity$1.run(CommitModeManager.kt:69)
at com.intellij.openapi.application.constraints.BaseConstrainedExecution$Companion$scheduleWithinConstraints$1.invoke(BaseConstrainedExecution.kt:68)
at com.intellij.openapi.application.constraints.BaseConstrainedExecution$Companion.scheduleWithinConstraints(BaseConstrainedExecution.kt:71)
at com.intellij.openapi.application.constraints.BaseConstrainedExecution.scheduleWithinConstraints(BaseConstrainedExecution.kt:38)
at com.intellij.openapi.application.impl.BaseExpirableExecutorMixinImpl.access$scheduleWithinConstraints$s1153900543(BaseExpirableExecutorMixinImpl.kt:12)
at com.intellij.openapi.application.impl.BaseExpirableExecutorMixinImpl$scheduleWithinConstraints$$inlined$Runnable$1.run(Runnable.kt:19)
at com.intellij.openapi.application.TransactionGuardImpl.runWithWritingAllowed(TransactionGuardImpl.java:215)
at com.intellij.openapi.application.TransactionGuardImpl.access$100(TransactionGuardImpl.java:22)
at com.intellij.openapi.application.TransactionGuardImpl$1.run(TransactionGuardImpl.java:197)
at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:873)
at com.intellij.openapi.application.impl.ApplicationImpl$3.run(ApplicationImpl.java:511)
at com.intellij.openapi.application.impl.FlushQueue.doRun(FlushQueue.java:69)
at com.intellij.openapi.application.impl.FlushQueue.runNextEvent(FlushQueue.java:112)
at com.intellij.openapi.application.impl.FlushQueue.flushNow(FlushQueue.java:42)
at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:776)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:727)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:746)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:898)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:746)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$6(IdeEventQueue.java:439)
at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:803)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$7(IdeEventQueue.java:438)
at com.intellij.openapi.application.TransactionGuardImpl.performActivity(TransactionGuardImpl.java:106)
at com.intellij.ide.IdeEventQueue.performActivity(IdeEventQueue.java:604)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$8(IdeEventQueue.java:436)
at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:873)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:484)
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)
System
WebStorm 2022.1.2
Build #WS-221.5787.30, built on May 31, 2022
Runtime version: 11.0.15+10-b2043.56 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Windows 10 10.0
GC: G1 Young Generation, G1 Old Generation
Memory: 2048M
Cores: 12
Non-Bundled Plugins:
some.awesome (1.14)
monokai-pro (1.8.1)
com.github.lppedd.idea-conventional-commit (0.21.0)
com.crunch42.openapi (1.34)
com.4lex4.intellij.solarized (2.4.0)
zielu.gittoolbox (212.9.0)
org.sonarlint.idea (6.7.0.45926)
mobi.hsz.idea.gitignore (4.4.0)
com.intellij.swagger (221.5787.13)
izhangzhihao.rainbow.brackets (6.24)
com.microsoft.vso.idea (1.162.0)
Got what the problem is. Easy to fix.
Will push an update on the weekend probably.
Now got this directly at start:
java.lang.IllegalArgumentException: Requested element count -2 is less than zero.
at kotlin.sequences.SequencesKt___SequencesKt.take(_Sequences.kt:557)
at com.github.lppedd.cc.vcs.InternalRecentCommitsService.parseMessage(InternalRecentCommitsService.kt:125)
at com.github.lppedd.cc.vcs.InternalRecentCommitsService.updateCachedTokens(InternalRecentCommitsService.kt:74)
at com.github.lppedd.cc.vcs.InternalRecentCommitsService.access$updateCachedTokens(InternalRecentCommitsService.kt:20)
at com.github.lppedd.cc.vcs.InternalRecentCommitsService$1.refreshed(InternalRecentCommitsService.kt:40)
at com.github.lppedd.cc.vcs.InternalVcsService.refresh(InternalVcsService.kt:65)
at com.github.lppedd.cc.CCProjectManagerListener.projectOpened$lambda-1$lambda-0(CCProjectManagerListener.kt:25)
at com.intellij.openapi.application.impl.ApplicationImpl$1.run(ApplicationImpl.java:295)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665)
at java.base/java.lang.Thread.run(Thread.java:829)
@rklec mmmm, that's quite strange.
The line is
.take(max(MAX_ELEMENTS - footerValues.size, 0))
How can this produce a -2? Maybe I'm getting dumber lol
Ahhh damn. I still have not published the update hahahaha
Sorry I totally forgot about this detail.
Published 0.22.0, closing.