def read_charlist(filename):
    with open(filename) as datafile:
        charlist = []
        for line in datafile:
            if '#' in line:
                line = line[:line.index('#')]
            line = line.strip()
            if not line:
                continue
            if line.startswith('U+'):
                line = line[2:]
            char = int(line, 16)
            charlist.append(char)
        return charlist
Returns a list of characters read from a charset text file.
dataset/ETHPy150Open google/roboto/scripts/subset_for_web.py/read_charlist