def METHOD_NAME(self, path):
    extension = os.path.splitext(path)[1]
    if extension.lower() not in RESOURCE_EXTENSIONS:
        extensions = seq2str(sorted(RESOURCE_EXTENSIONS))
        raise DataError(f"Invalid resource file extension '{extension}'. "
                        f"Supported extensions are {extensions}.")