private static @Nullable String findAbsoluteFilePathByRelativePath(@NotNull Module module,
                                                                     @NotNull String relativePath) {
    String filename = new File(relativePath).getName();
    GlobalSearchScope moduleScope = GlobalSearchScope.moduleScope(module);
    Collection<VirtualFile> filesByName = ReadAction.compute(() -> FilenameIndex.getVirtualFilesByName(filename, moduleScope));
    for (VirtualFile file : filesByName) {
      String path = file.getPath();
      if (path.endsWith(relativePath) || path.endsWith(relativePath.replaceAll("/", "\\"))) {
        return "file://" + path; // NON-NLS
      }
    }
    return null;
  }
private static @Nullable String findAbsoluteFilePathByRelativePath(@NotNull Module module,
                                                                     @NotNull String relativePath)