Duplicate line markers immediately after opening a file in an editor tab

I’m seeing an issue where the same line marker provider is being called on two different threads simultaneously:

2026-05-19 09:03:23,825 [ 527170]   FINE - #com.illuminatedcloud.intellij.apex.editor.lineMarker.ApexRelatedItemLineMarkerProvider - Added 2 related item line markers to 'Individual.hashCode()' on thread JobScheduler FJ pool 12/11: [(1958,1966) -> psi:range=(1958,1966),type=Identikit(class='com.intellij.psi.impl.source.tree.LeafPsiElement', elementType=IDENT, fileLanguage='Apex') (icon: PatchedRasterizedImageDataLoader(classLoader=com.intellij.util.lang.PathClassLoader@7946e1f4, path=expui/gutter/overridingMethod.svg)), (1958,1966) -> psi:range=(1958,1966),type=Identikit(class='com.intellij.psi.impl.source.tree.LeafPsiElement', elementType=IDENT, fileLanguage='Apex') (icon: PatchedRasterizedImageDataLoader(classLoader=com.intellij.util.lang.PathClassLoader@7946e1f4, path=expui/gutter/overridenMethod.svg))]

2026-05-19 09:03:23,825 [ 527170]   FINE - #com.illuminatedcloud.intellij.apex.editor.lineMarker.ApexRelatedItemLineMarkerProvider - Added 2 related item line markers to 'Individual.hashCode()' on thread JobScheduler FJ pool 3/11: [(1958,1966) -> psi:range=(1958,1966),type=Identikit(class='com.intellij.psi.impl.source.tree.LeafPsiElement', elementType=IDENT, fileLanguage='Apex') (icon: PatchedRasterizedImageDataLoader(classLoader=com.intellij.util.lang.PathClassLoader@7946e1f4, path=expui/gutter/overridingMethod.svg)), (1958,1966) -> psi:range=(1958,1966),type=Identikit(class='com.intellij.psi.impl.source.tree.LeafPsiElement', elementType=IDENT, fileLanguage='Apex') (icon: PatchedRasterizedImageDataLoader(classLoader=com.intellij.util.lang.PathClassLoader@7946e1f4, path=expui/gutter/overridenMethod.svg))]

resulting in some line markers being added in duplicate:

image

This seems to happen primarily (only?) immediately after the document is opened in an editor tab. As soon as the document is modified, the duplicate line markers are removed.

Is there something specific I need to be doing to avoid this situation? As you can see in the debug log entries above, the added line markers are identical, so I’m surprised they’re not being deduped.

Hello. Could you please create an issue in youtrack.jetbrains.com so that we can try to reproduce this? thank you.

Done: