import re


def load_topics(topic_path):
    """Loads a list of topics from the csv file at the provided path.
    Filters out topics that are to long."""
    topics = []
    with open(topic_path, 'r') as topic_file:
        for line in topic_file:
            if len(line) > 50 and not re.match('^[0-9a-zA-Z\-\" ]+$',line):
                continue
            topics.append((line.strip().replace('"',''), ))
    return topics