def sanitize_string(s, extra_chars=''):
    chars = string.ascii_letters + string.digits + extra_chars
    return ''.join([c for c in s if c in chars])
dataset/ETHPy150Open eleme/polaris/polaris/utils.py/sanitize_string/original