docs: @CheckForNull
    public static String canonicalPath(@Nullable File file) {
      if (file == null) {
        return null;
      }
      try {
        return FilenameUtils.separatorsToUnix(file.getCanonicalPath());
      } catch (IOException e) {
        throw new IllegalStateException("Fail to get the canonical path of " + file.getAbsolutePath(), e);
      }
    }