pest-intellij
pest-intellij copied to clipboard
java.lang.ArrayIndexOutOfBoundsException DuplicateCustomExpectationInspection
Q | A |
---|---|
Bug report? | yes |
Plugin version | 1.7.0 |
Pest version | 1.21.3 |
IntelliJ version | PS-222.3345.135 |
OS | Linux |
Description
This seems to be related to custom expectations. I enabled it again in the registry and made sure the directory is writable, now I found this in the logs.
Stacktrace
com.intellij.util.indexing.impl.MapReduceIndexMappingException: java.lang.ArrayIndexOutOfBoundsException: Index 1 out of bounds for length 1
com.intellij.util.indexing.impl.MapReduceIndexMappingException: java.lang.ArrayIndexOutOfBoundsException: Index 1 out of bounds for length 1
at com.intellij.util.indexing.impl.MapReduceIndex.mapInputAndPrepareUpdate(MapReduceIndex.java:250)
at com.intellij.indexing.composite.CompositeInvertedIndexBase.updateBaseIndex(CompositeInvertedIndexBase.java:277)
at com.intellij.indexing.composite.CompositeInvertedIndexBase.mapInputAndPrepareUpdate(CompositeInvertedIndexBase.java:60)
at com.intellij.indexing.composite.CompositeInvertedIndexBase.mapInputAndPrepareUpdate(CompositeInvertedIndexBase.java:27)
at com.intellij.util.indexing.FileBasedIndexImpl.updateIndexInNonCancellableSection(FileBasedIndexImpl.java:1064)
at com.intellij.util.indexing.FileBasedIndexImpl.lambda$indexUnsavedDocument$17(FileBasedIndexImpl.java:1038)
at com.intellij.openapi.fileTypes.impl.FileTypeManagerImpl.freezeFileTypeTemporarilyWithProvidedValueIn(FileTypeManagerImpl.java:670)
at com.intellij.openapi.fileTypes.impl.FileTypeManagerImpl.freezeFileTypeTemporarilyIn(FileTypeManagerImpl.java:653)
at com.intellij.util.indexing.FileBasedIndexImpl.indexUnsavedDocument(FileBasedIndexImpl.java:1026)
at com.intellij.util.indexing.RegisteredIndexes$DocumentUpdateTask.doProcess(RegisteredIndexes.java:183)
at com.intellij.util.indexing.RegisteredIndexes$DocumentUpdateTask.doProcess(RegisteredIndexes.java:174)
at com.intellij.util.indexing.UpdateTask.process(UpdateTask.java:63)
at com.intellij.util.indexing.UpdateTask.processAll(UpdateTask.java:32)
at com.intellij.util.indexing.FileBasedIndexImpl.lambda$indexUnsavedDocuments$16(FileBasedIndexImpl.java:992)
at com.intellij.util.indexing.StorageBufferingHandler.runUpdate(StorageBufferingHandler.java:22)
at com.intellij.util.indexing.FileBasedIndexImpl.indexUnsavedDocuments(FileBasedIndexImpl.java:992)
at com.intellij.util.indexing.FileBasedIndexImpl.ensureUpToDate(FileBasedIndexImpl.java:813)
at com.intellij.util.indexing.FileBasedIndexEx.processExceptions(FileBasedIndexEx.java:292)
at com.intellij.util.indexing.FileBasedIndexEx.getFileData(FileBasedIndexEx.java:192)
at com.intellij.util.indexing.FileBasedIndexImpl.getFileData(FileBasedIndexImpl.java:1106)
at com.pestphp.pest.inspections.DuplicateCustomExpectationInspection$buildVisitor$1.visitPhpMethodReference(DuplicateCustomExpectationInspection.kt:28)
at com.jetbrains.php.lang.psi.elements.impl.MethodReferenceImpl.accept(MethodReferenceImpl.java:44)
at com.jetbrains.php.lang.psi.elements.impl.PhpASTElementImpl.accept(PhpASTElementImpl.java:26)
at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$processInOrder$10(InspectionRunner.java:317)
at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1154)
at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$processInOrder$11(InspectionRunner.java:325)
at com.intellij.openapi.application.impl.ReadMostlyRWLock.executeByImpatientReader(ReadMostlyRWLock.java:174)
at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:215)
at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$processInOrder$12(InspectionRunner.java:331)
at com.intellij.util.AstLoadingFilter.forceAllowTreeLoading(AstLoadingFilter.java:159)
at com.intellij.util.AstLoadingFilter.forceAllowTreeLoading(AstLoadingFilter.java:151)
at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$processInOrder$13(InspectionRunner.java:294)
at com.intellij.util.AstLoadingFilter.disallowTreeLoading(AstLoadingFilter.java:130)
at com.intellij.util.AstLoadingFilter.disallowTreeLoading(AstLoadingFilter.java:119)
at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$processInOrder$14(InspectionRunner.java:294)
at com.intellij.concurrency.JobLauncherImpl$1MyProcessQueueTask.lambda$call$0(JobLauncherImpl.java:297)
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.concurrency.JobLauncherImpl$1MyProcessQueueTask.call(JobLauncherImpl.java:282)
at com.intellij.concurrency.JobLauncherImpl$1MyProcessQueueTask.call(JobLauncherImpl.java:270)
at java.base/java.util.concurrent.ForkJoinTask$AdaptedCallable.exec(ForkJoinTask.java:1428)
at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)
at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)
at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)
at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)
at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 1 out of bounds for length 1
at com.pestphp.pest.features.customExpectations.ExpectationUtilKt.toMethod(expectationUtil.kt:108)
at com.pestphp.pest.features.customExpectations.CustomExpectationIndex.getIndexer$lambda-1(CustomExpectationIndex.kt:40)
at com.intellij.util.indexing.impl.MapReduceIndex.mapByIndexer(MapReduceIndex.java:308)
at com.intellij.util.indexing.impl.MapReduceIndex.mapInput(MapReduceIndex.java:299)
at com.intellij.util.indexing.impl.storage.VfsAwareMapReduceIndex.mapInput(VfsAwareMapReduceIndex.java:176)
at com.intellij.util.indexing.impl.storage.VfsAwareMapReduceIndex.mapInput(VfsAwareMapReduceIndex.java:40)
at com.intellij.util.indexing.impl.MapReduceIndex.mapInputAndPrepareUpdate(MapReduceIndex.java:244)
... 48 more