Closed pquerner closed 1 year ago
Another one, while visiting / debugging \Mage_Adminhtml_Block_System_Config_Form::initFields
com.intellij.diagnostic.PluginException: TypeProvider contract violation? by class com.magicento.extensions.FactoryTypeProvider3 on $optionArray [Plugin: Magicento]
at com.intellij.diagnostic.PluginProblemReporterImpl.createPluginExceptionByClass(PluginProblemReporterImpl.java:23)
at com.intellij.diagnostic.PluginException.createByClass(PluginException.java:89)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.lambda$getTypeFromAST$1(PhpTypeInfo.java:118)
at com.intellij.openapi.util.RecursionManager$1.computePreventingRecursion(RecursionManager.java:112)
at com.intellij.openapi.util.RecursionGuard.doPreventingRecursion(RecursionGuard.java:42)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeFromAST(PhpTypeInfo.java:80)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeCached(PhpTypeInfo.java:63)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:45)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:31)
at com.jetbrains.php.codeInsight.typeInference.PhpVariableInferredTypeAnalyzerProcessor.getType(PhpVariableInferredTypeAnalyzerProcessor.java:574)
at com.jetbrains.php.codeInsight.typeInference.PhpVariableInferredTypeAnalyzerProcessor.getType(PhpVariableInferredTypeAnalyzerProcessor.java:566)
at com.jetbrains.php.codeInsight.typeInference.PhpVariableInferredTypeAnalyzerProcessor.processAccessVariableInstruction(PhpVariableInferredTypeAnalyzerProcessor.java:134)
at com.jetbrains.php.codeInsight.controlFlow.instructions.impl.PhpAccessVariableInstructionImpl.process(PhpAccessVariableInstructionImpl.java:46)
at com.jetbrains.php.codeInsight.controlFlow.PhpControlFlowUtil.processPredecessors(PhpControlFlowUtil.java:344)
at com.jetbrains.php.codeInsight.controlFlow.PhpControlFlowUtil.processPredecessors(PhpControlFlowUtil.java:314)
at com.jetbrains.php.codeInsight.controlFlow.PhpControlFlowUtil.processPredecessors(PhpControlFlowUtil.java:283)
at com.jetbrains.php.codeInsight.typeInference.PhpVariableInferredTypeAnalyzerProcessor.inferType(PhpVariableInferredTypeAnalyzerProcessor.java:658)
at com.jetbrains.php.codeInsight.typeInference.PhpVariableInferredTypeAnalyzerProcessor.inferType(PhpVariableInferredTypeAnalyzerProcessor.java:650)
at com.jetbrains.php.codeInsight.typeInference.PhpVariableInferredTypeAnalyzerProcessor.inferTypeDfaBasedTypeStateAware(PhpVariableInferredTypeAnalyzerProcessor.java:582)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.inferVariableType(PhpTypeAnalyserVisitor.java:473)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.addInferredType(PhpTypeAnalyserVisitor.java:423)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.visitPhpVariable(PhpTypeAnalyserVisitor.java:397)
at com.jetbrains.php.lang.psi.elements.impl.VariableImpl.accept(VariableImpl.java:141)
at com.jetbrains.php.lang.psi.elements.impl.PhpPsiElementImpl.accept(PhpPsiElementImpl.java:73)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.getTypeFromAST(PhpTypeAnalyserVisitor.java:193)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.lambda$getTypeFromAST$1(PhpTypeInfo.java:82)
at com.intellij.openapi.util.RecursionManager$1.computePreventingRecursion(RecursionManager.java:112)
at com.intellij.openapi.util.RecursionGuard.doPreventingRecursion(RecursionGuard.java:42)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeFromAST(PhpTypeInfo.java:80)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeCached(PhpTypeInfo.java:63)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:45)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:31)
at com.jetbrains.php.lang.psi.elements.impl.PhpTypedElementImpl.getType(PhpTypedElementImpl.java:24)
at com.jetbrains.php.lang.psi.elements.impl.VariableImpl.getType(VariableImpl.java:667)
at com.jetbrains.php.lang.psi.resolve.types.PhpType.add(PhpType.java:554)
at com.jetbrains.php.lang.inspections.type.PhpParamsInspection.checkParametersTypes(PhpParamsInspection.java:168)
at com.jetbrains.php.lang.inspections.type.PhpParamsInspection.lambda$checkCall$1(PhpParamsInspection.java:135)
at com.jetbrains.php.lang.inspections.type.PhpParamsInspection.processSignatures(PhpParamsInspection.java:397)
at com.jetbrains.php.lang.inspections.type.PhpParamsInspection.checkCall(PhpParamsInspection.java:131)
at com.jetbrains.php.lang.inspections.type.PhpParamsInspection$1.visitPhpMethodReference(PhpParamsInspection.java:89)
at com.jetbrains.php.lang.psi.elements.impl.MethodReferenceImpl.accept(MethodReferenceImpl.java:45)
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:323)
at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1102)
at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$processInOrder$11(InspectionRunner.java:331)
at com.intellij.openapi.application.impl.ReadMostlyRWLock.executeByImpatientReader(ReadMostlyRWLock.java:229)
at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:187)
at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$processInOrder$12(InspectionRunner.java:337)
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:300)
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:300)
at com.intellij.concurrency.JobLauncherImpl$1MyProcessQueueTask.lambda$call$0(JobLauncherImpl.java:299)
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.concurrency.JobLauncherImpl$1MyProcessQueueTask.call(JobLauncherImpl.java:284)
at com.intellij.concurrency.JobLauncherImpl$1MyProcessQueueTask.call(JobLauncherImpl.java:272)
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: com.intellij.diagnostic.PluginException: TypeProvider contract violation? by class com.magicento.extensions.FactoryTypeProvider3 on $sourceModel->$method() [Plugin: Magicento]
at com.intellij.diagnostic.PluginProblemReporterImpl.createPluginExceptionByClass(PluginProblemReporterImpl.java:23)
at com.intellij.diagnostic.PluginException.createByClass(PluginException.java:89)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.lambda$getTypeFromAST$1(PhpTypeInfo.java:118)
at com.intellij.openapi.util.RecursionManager$1.computePreventingRecursion(RecursionManager.java:112)
at com.intellij.openapi.util.RecursionGuard.doPreventingRecursion(RecursionGuard.java:42)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeFromAST(PhpTypeInfo.java:80)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeCached(PhpTypeInfo.java:63)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:45)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:31)
at com.jetbrains.php.lang.psi.elements.impl.PhpReferenceImpl.getType(PhpReferenceImpl.java:251)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.addTypeFromExpression(PhpTypeAnalyserVisitor.java:160)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.addInferredType(PhpTypeAnalyserVisitor.java:419)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.visitPhpVariable(PhpTypeAnalyserVisitor.java:397)
at com.jetbrains.php.lang.psi.elements.impl.VariableImpl.accept(VariableImpl.java:141)
at com.jetbrains.php.lang.psi.elements.impl.PhpPsiElementImpl.accept(PhpPsiElementImpl.java:73)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeAnalyserVisitor.getTypeFromAST(PhpTypeAnalyserVisitor.java:193)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.lambda$getTypeFromAST$1(PhpTypeInfo.java:82)
at com.intellij.openapi.util.RecursionManager$1.computePreventingRecursion(RecursionManager.java:112)
at com.intellij.openapi.util.RecursionGuard.doPreventingRecursion(RecursionGuard.java:42)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeFromAST(PhpTypeInfo.java:80)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getTypeCached(PhpTypeInfo.java:63)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:45)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.getType(PhpTypeInfo.java:31)
at com.jetbrains.php.lang.psi.elements.impl.PhpTypedElementImpl.getType(PhpTypedElementImpl.java:24)
at com.jetbrains.php.lang.psi.elements.impl.VariableImpl.getType(VariableImpl.java:667)
at com.jetbrains.php.lang.psi.elements.impl.VariableImpl.getSignatures(VariableImpl.java:614)
at com.jetbrains.php.lang.psi.elements.impl.VariableImpl.getSignatureParts(VariableImpl.java:594)
at com.jetbrains.php.lang.psi.elements.PhpReference.getSignature(PhpReference.java:68)
at com.magicento.extensions.FactoryTypeProvider3.getTypeString(FactoryTypeProvider3.java:620)
at com.magicento.extensions.FactoryTypeProvider3.getType(FactoryTypeProvider3.java:658)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.lambda$getTypeFromAST$1(PhpTypeInfo.java:106)
... 65 more
Caused by: java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "<local6>" is null
at com.magicento.extensions.FactoryTypeProvider3.getTypeForMethodReference(FactoryTypeProvider3.java:255)
at com.magicento.extensions.FactoryTypeProvider3.getTypeString(FactoryTypeProvider3.java:530)
at com.magicento.extensions.FactoryTypeProvider3.getType(FactoryTypeProvider3.java:658)
at com.jetbrains.php.lang.psi.resolve.types.PhpTypeInfo.lambda$getTypeFromAST$1(PhpTypeInfo.java:106)
... 93 more
Please try with version 3.3.8
3.3.8 fixed this
Magicento 3.3.6
withPhpstorm 2023.1