void (@NotNull Throwable t, @NotNull ExternalAnnotator<?,?> annotator, @NotNull PsiFile root) { if (t instanceof ProcessCanceledException pce) throw pce; VirtualFile file = root.getVirtualFile(); String path = file != null ? file.getPath() : root.getName(); String message = "annotator: " + annotator + " (" + annotator.getClass() + ")"; PluginException pe = PluginException.createByClass(message, t, annotator.getClass()); LOG.error("ExternalToolPass: ", pe, new Attachment("root_path.txt", path)); }