private static boolean isValidEpName(GenericAttributeValue<String> nameAttrValue) {
    if (!nameAttrValue.exists()) {
      return true;
    }
    @NonNls String name = nameAttrValue.getValue();

    // skip some known offenders in IJ project
    if (name != null
        && (StringUtil.startsWith(name, "Pythonid.") ||
            StringUtil.startsWith(name, "DevKit."))) {
      if (IntelliJProjectUtil.isIntelliJPlatformProject(nameAttrValue.getManager().getProject())) {
        return true;
      }
    }

    if (StringUtil.isEmpty(name) ||
        !Character.isLowerCase(name.charAt(0)) || // also checks that the name doesn't start with a dot
        StringUtil.toUpperCase(name).equals(name) || // not all uppercase chars
        !StringUtil.isLatinAlphanumeric(name.replace(".", "")) ||
        name.charAt(name.length() - 1) == '.') {
      return false;
    }

    List<String> fragments = StringUtil.split(name, ".");
    if (ContainerUtil.exists(fragments, f -> Character.isUpperCase(f.charAt(0)))) {
      return false;
    }

    String epName = fragments.get(fragments.size() - 1);
    List<String> butlast = fragments.subList(0, fragments.size() - 1);
    List<String> words = StringUtil.getWordsIn(epName);
    return !ContainerUtil.exists(words, w -> ContainerUtil.exists(butlast, f -> StringUtil.equalsIgnoreCase(w, f)));
  }
private static boolean isValidEpName(GenericAttributeValue<String> nameAttrValue)