Skip to content

fix: wrap FilenameIndex lookups in ReadAction to fix read-access crash on newer IDEs#98

Open
wowkin2 wants to merge 1 commit into
LefterisXris:mainfrom
wowkin2:fix/2026_make_it_work
Open

fix: wrap FilenameIndex lookups in ReadAction to fix read-access crash on newer IDEs#98
wowkin2 wants to merge 1 commit into
LefterisXris:mainfrom
wowkin2:fix/2026_make_it_work

Conversation

@wowkin2

@wowkin2 wowkin2 commented Jun 25, 2026

Copy link
Copy Markdown

Fix for #97

On newer IntelliJ platforms the EDT no longer holds an implicit read lock, and SlowOperations.allowSlowOperations() does not grant read access.

Calling FilenameIndex.getVirtualFilesByName() from the UI thread therefore throws:
"Read access is allowed from inside read-action only".

Wrap the index lookups in ReadAction.compute(...), matching the existing pattern in StateManager, so navigation works on both old and new platforms.

  • Navigator.navigate (step click — the reported crash)
  • ToolPaneWindow.jumpToSourceTourListener (jump to tour source)
  • Validator.validateTours (tour validation, previously unguarded)

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

Successfully merging this pull request may close these issues.

1 participant