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

IllegalStateException: ElementIconRequest hashCode changed while stored in Caffeine cache #25

Open
danberindei opened this issue Dec 8, 2023 · 0 comments

Comments

@danberindei
Copy link

I started seeing this exception after upgrading to IntelliJ 2023.2.5.

java.lang.IllegalStateException: An invalid state was detected that occurs if the key's equals or hashCode was modified while it resided in the cache. This violation of the Map  contract can lead to non-deterministic behavior (key: com.intellij.psi.impl.ElementBase$ElementIconRequest@20d0aae, key type: ElementIconRequest, node type: PSMS, cache type: SSMS).
	at com.github.benmanes.caffeine.cache.BoundedLocalCache.requireIsAlive(BoundedLocalCache.java:294)
	at com.github.benmanes.caffeine.cache.BoundedLocalCache.lambda$doComputeIfAbsent$14(BoundedLocalCache.java:2698)
	at java.base/java.util.concurrent.ConcurrentHashMap.compute(ConcurrentHashMap.java:1940)
	at com.github.benmanes.caffeine.cache.BoundedLocalCache.doComputeIfAbsent(BoundedLocalCache.java:2683)
	at com.github.benmanes.caffeine.cache.BoundedLocalCache.computeIfAbsent(BoundedLocalCache.java:2666)
	at com.github.benmanes.caffeine.cache.LocalCache.computeIfAbsent(LocalCache.java:112)
	at com.github.benmanes.caffeine.cache.LocalManualCache.get(LocalManualCache.java:62)
	at com.intellij.ui.IconDeferrerImpl.defer(IconDeferrerImpl.kt:75)
	at com.intellij.ui.icons.CoreIconManager.createDeferredIcon(CoreIconManager.kt:117)
	at com.intellij.psi.impl.ElementBase.computeIcon(ElementBase.java:85)
	at com.intellij.psi.impl.ElementBase.getIcon(ElementBase.java:62)
	at com.andrey4623.rainbowcsv.CsvFile.getIcon(CsvFile.java:30)
	at com.intellij.ide.projectView.impl.nodes.PsiFileNode.updateImpl(PsiFileNode.java:65)
	at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.lambda$doUpdate$1(AbstractPsiBasedNode.java:213)
	at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:895)
	at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.doUpdate(AbstractPsiBasedNode.java:166)
	at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.lambda$update$0(AbstractPsiBasedNode.java:162)
	at com.intellij.util.AstLoadingFilter.lambda$toComputable$2(AstLoadingFilter.java:172)
	at com.intellij.util.AstLoadingFilter.disallowTreeLoading(AstLoadingFilter.java:130)
	at com.intellij.util.AstLoadingFilter.disallowTreeLoading(AstLoadingFilter.java:119)
	at com.intellij.util.AstLoadingFilter.disallowTreeLoading(AstLoadingFilter.java:109)
	at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.update(AbstractPsiBasedNode.java:162)
	at com.intellij.ide.util.treeView.PresentableNodeDescriptor.getUpdatedPresentation(PresentableNodeDescriptor.java:88)
	at com.intellij.ide.util.treeView.PresentableNodeDescriptor.update(PresentableNodeDescriptor.java:32)
	at com.intellij.ui.tree.StructureTreeModel$Node.update(StructureTreeModel.java:486)
	at com.intellij.ui.tree.StructureTreeModel.invalidateInternal(StructureTreeModel.java:244)
	at com.intellij.ui.tree.StructureTreeModel.lambda$invalidate$5(StructureTreeModel.java:208)
	at com.intellij.ui.tree.StructureTreeModel.lambda$onValidThread$2(StructureTreeModel.java:143)
	at com.intellij.ui.tree.StructureTreeModel.lambda$onValidThread$1(StructureTreeModel.java:121)
	at com.intellij.util.concurrency.Invoker$Task.run(Invoker.java:306)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant