Haehnchen / idea-php-annotation-plugin

Add PHP annotation support for PhpStorm and IntelliJ
https://plugins.jetbrains.com/plugin/7320
MIT License
251 stars 41 forks source link

[11.0.0 + 2024.2 Beta] Opening a PHP file with annotations causes an error in the plugin #309

Closed luimen6 closed 3 months ago

luimen6 commented 3 months ago

PhpStorm 2024.2 Beta Build #PS-242.20224.112, built on July 19, 2024 PHP Annotations 11.0.0

java.lang.NoSuchFieldError: Class com.jetbrains.php.lang.documentation.phpdoc.parser.PhpDocElementTypes does not have member field 'com.jetbrains.php.lang.psi.stubs.PhpStubElementType phpDocTag'
    at de.espend.idea.php.annotation.pattern.AnnotationPattern.getDefaultPropertyValueString(AnnotationPattern.java:164)
    at de.espend.idea.php.annotation.reference.AnnotationPropertyValueReferenceContributor.registerReferenceProviders(AnnotationPropertyValueReferenceContributor.java:34)
    at com.intellij.psi.impl.source.resolve.reference.ReferenceProvidersRegistryImpl.registerContributedReferenceProviders(ReferenceProvidersRegistryImpl.java:94)
    at com.intellij.psi.impl.source.resolve.reference.ReferenceProvidersRegistryImpl.createRegistrar(ReferenceProvidersRegistryImpl.java:63)
    at java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
    at com.intellij.psi.impl.source.resolve.reference.ReferenceProvidersRegistryImpl.getRegistrar(ReferenceProvidersRegistryImpl.java:99)
    at com.intellij.psi.impl.source.resolve.reference.ReferenceProvidersRegistryImpl.doGetReferencesFromProviders(ReferenceProvidersRegistryImpl.java:120)
    at com.intellij.psi.impl.source.resolve.reference.ReferenceProvidersRegistry.lambda$getReferencesFromProviders$0(ReferenceProvidersRegistry.java:44)
    at com.intellij.psi.util.CachedValuesManager$1.compute(CachedValuesManager.java:173)
    at com.intellij.psi.impl.PsiCachedValueImpl$Direct.doCompute(PsiCachedValueImpl.kt:77)
    at com.intellij.util.CachedValueBase.lambda$getValueWithLock$3(CachedValueBase.java:236)
    at com.intellij.util.CachedValueBase.computeData(CachedValueBase.java:43)
    at com.intellij.util.CachedValueBase.lambda$getValueWithLock$4(CachedValueBase.java:236)
    at com.intellij.openapi.util.RecursionManager$1.computePreventingRecursion(RecursionManager.java:111)
    at com.intellij.openapi.util.RecursionGuard.doPreventingRecursion(RecursionGuard.java:27)
    at com.intellij.openapi.util.RecursionManager.doPreventingRecursion(RecursionManager.java:66)
    at com.intellij.util.CachedValueBase.getValueWithLock(CachedValueBase.java:237)
    at com.intellij.psi.impl.PsiCachedValueImpl$Direct.getValue(PsiCachedValueImpl.kt:81)
    at com.intellij.util.CachedValuesManagerImpl.getCachedValue(CachedValuesManagerImpl.java:83)
    at com.intellij.psi.util.CachedValuesManager.getCachedValue(CachedValuesManager.java:170)
    at com.intellij.psi.util.CachedValuesManager.getCachedValue(CachedValuesManager.java:136)
    at com.intellij.psi.impl.source.resolve.reference.ReferenceProvidersRegistry.getReferencesFromProviders(ReferenceProvidersRegistry.java:42)
    at com.intellij.psi.impl.source.resolve.reference.ReferenceProvidersRegistry.getReferencesFromProviders(ReferenceProvidersRegistry.java:35)
    at com.jetbrains.php.lang.psi.elements.impl.StringLiteralExpressionImpl.getReferences(StringLiteralExpressionImpl.java:490)
    at com.intellij.psi.impl.SharedPsiElementImplUtil.addReferences(SharedPsiElementImplUtil.java:58)
    at com.intellij.psi.impl.SharedPsiElementImplUtil.findReferenceAt(SharedPsiElementImplUtil.java:33)
    at com.intellij.psi.MultiplePsiFilesPerDocumentFileViewProvider.findReferenceAt(MultiplePsiFilesPerDocumentFileViewProvider.java:162)
    at com.intellij.psi.impl.source.PsiFileImpl.findReferenceAt(PsiFileImpl.java:535)
    at com.intellij.codeInsight.TargetElementUtilBase.findReference(TargetElementUtilBase.java:189)
    at com.intellij.codeInsight.TargetElementUtil.findReference(TargetElementUtil.java:94)
    at com.intellij.model.psi.impl.TargetsKt.fromTargetEvaluator(targets.kt:167)
    at com.intellij.model.psi.impl.TargetsKt.declarationsOrReferences(targets.kt:136)
    at com.intellij.model.psi.impl.TargetsKt.declaredReferencedData(targets.kt:42)
    at com.intellij.model.psi.impl.TargetsKt.targetSymbols(targets.kt:24)
    at com.intellij.codeInsight.daemon.impl.IdentifierHighlighterPass.getTargetSymbols(IdentifierHighlighterPass.java:219)
    at com.intellij.codeInsight.daemon.impl.IdentifierHighlighterPass.highlightReferencesAndDeclarations(IdentifierHighlighterPass.java:210)
    at com.intellij.codeInsight.daemon.impl.IdentifierHighlighterPass.doCollectInformation(IdentifierHighlighterPass.java:99)
    at com.intellij.codeInsight.highlighting.BackgroundHighlighter.lambda$submitIdentifierHighlighterPass$8(BackgroundHighlighter.java:317)
    at com.intellij.codeInsight.daemon.impl.HighlightingSessionImpl.runInsideHighlightingSession(HighlightingSessionImpl.java:170)
    at com.intellij.codeInsight.highlighting.BackgroundHighlighter.lambda$submitIdentifierHighlighterPass$9(BackgroundHighlighter.java:314)
    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.util.ProgressIndicatorUtils.lambda$runWithWriteActionPriority$1(ProgressIndicatorUtils.java:138)
    at com.intellij.openapi.progress.ProgressManager.lambda$runProcess$0(ProgressManager.java:96)
    at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:217)
    at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$13(CoreProgressManager.java:660)
    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.executeProcessUnderProgress(CoreProgressManager.java:659)
    at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:79)
    at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:202)
    at com.intellij.openapi.progress.ProgressManager.runProcess(ProgressManager.java:96)
    at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runWithWriteActionPriority(ProgressIndicatorUtils.java:135)
    at com.intellij.codeInsight.highlighting.BackgroundHighlighter.lambda$submitIdentifierHighlighterPass$10(BackgroundHighlighter.java:311)
    at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$OTelMonitor.callWrapped(NonBlockingReadActionImpl.java:840)
    at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$OTelMonitor$MonitoredComputation.call(NonBlockingReadActionImpl.java:872)
    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.AnyThreadWriteThreadingSupport.tryRunReadAction(AnyThreadWriteThreadingSupport.kt:291)
    at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:965)
    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.util.ProgressIndicatorUtils.lambda$runWithWriteActionPriority$1(ProgressIndicatorUtils.java:138)
    at com.intellij.openapi.progress.ProgressManager.lambda$runProcess$0(ProgressManager.java:96)
    at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:217)
    at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$13(CoreProgressManager.java:660)
    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.executeProcessUnderProgress(CoreProgressManager.java:659)
    at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:79)
    at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:202)
    at com.intellij.openapi.progress.ProgressManager.runProcess(ProgressManager.java:96)
    at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runWithWriteActionPriority(ProgressIndicatorUtils.java:135)
    at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runInReadActionWithWriteActionPriority(ProgressIndicatorUtils.java:93)
    at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$Submission.attemptComputation(NonBlockingReadActionImpl.java:567)
    at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$Submission.lambda$transferToBgThread$1(NonBlockingReadActionImpl.java:466)
    at com.intellij.openapi.application.impl.NonBlockingReadActionImpl$Submission.lambda$transferToBgThread$2(NonBlockingReadActionImpl.java:481)
    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
    at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:735)
    at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:732)
    at java.base/java.security.AccessController.doPrivileged(AccessController.java:400)
    at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:732)
    at java.base/java.lang.Thread.run(Thread.java:1583)
Haehnchen commented 3 months ago

Checked in final build for "2024.2", it looks like field was reimplemented. So no error is triggered.