def parse_mapping_file(filename):
    """Parse mapping file."""
    mappings = {}
    with open(filename) as handle:
        for line in handle:
            line = line.strip().split()
            if len(line) < 2 or line[1] == '':
                continue
            mappings[line[0]] = line[1]
    return mappings
