Skip to content

Conversation

@jnareb
Copy link
Contributor

@jnareb jnareb commented Sep 17, 2025

This should fix the sporadic RuntimeExceptionWithAttachments exception in CodeGRITS plugin that happens on some projects when running eye tracker.

  com.intellij.openapi.diagnostic.RuntimeExceptionWithAttachments:
  Read access is allowed from inside read-action only (see Application.runReadAction());
  If you access or modify model on EDT consider wrapping your code in WriteIntentReadAction ;
  see https://jb.gg/ij-platform-threading for details
  [...]
    at trackers.EyeTracker.getASTStructureElement(EyeTracker.java:450)
    at trackers.EyeTracker.lambda$processRawData$1(EyeTracker.java:306)

This fix is based on the https://stackoverflow.com/q/76809649 and the discussion in issue #17 .


Testing this fix shows no crashes where there were previously, but this is does not prove that the fix is correct.

This should fix the sporadic RuntimeExceptionWithAttachments exception
in CodeGRITS plugin that happens on some projects when running eye
tracker.

  com.intellij.openapi.diagnostic.RuntimeExceptionWithAttachments:
  Read access is allowed from inside read-action only (see Application.runReadAction());
  If you access or modify model on EDT consider wrapping your code in WriteIntentReadAction ;
  see https://jb.gg/ij-platform-threading for details
  [...]
    at trackers.EyeTracker.getASTStructureElement(EyeTracker.java:450)
    at trackers.EyeTracker.lambda$processRawData$1(EyeTracker.java:306)

This fix is based on the  https://stackoverflow.com/q/76809649 and
the discussion in issue codegrits#17 .
@TTangNingzhi TTangNingzhi merged commit 201028b into codegrits:main Sep 19, 2025
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.

2 participants