def get_all_genres(repo: AbstractRepository):
    genres = []

    for genre in repo.get_genres():
        genres.append(genre)

    if genres is []:
        raise NonExistentGenreException

    return sorted(genres)
def get_genre_names(repo:AbstractRepository) -> List[str]:
    genres = repo.get_genres()
    genre_names = [genre.genre_name for genre in genres]

    return genre_names