def split_filter_value_for_quotes(value):
 validate_quotes(value)
 tmp = re.compile('\n        "(                 # if found a double-quote\n           [^\\"\\\\]*        # take characters either non-quotes or backslashes\n           (?:\\\\.          # take backslashes and character after it\n            [^\\"\\\\]*)*     # take characters either non-quotes or backslashes\n         )                 # before double-quote\n        ",?                # a double-quote with comma maybe\n        | ([^,]+),?        # if not found double-quote take any non-comma\n                           # characters with comma maybe\n        | ,                # if we have only comma take empty string\n        ', re.VERBOSE)
 return [(val[0] or val[1]) for val in re.findall(tmp, value)]

def split_filter_value_for_quotes ( value ) : validate_quotes ( value ) tmp = re . compile ( '\n        "(                 # if found a double-quote\n           [^\\"\\\\]*        # take characters either non-quotes or backslashes\n           (?:\\\\.          # take backslashes and character after it\n            [^\\"\\\\]*)*     # take characters either non-quotes or backslashes\n         )                 # before double-quote\n        ",?                # a double-quote with comma maybe\n        | ([^,]+),?        # if not found double-quote take any non-comma\n                           # characters with comma maybe\n        | ,                # if we have only comma take empty string\n        ' , re . VERBOSE ) return [ ( val [ 0 ] or val [ 1 ] ) for val in re . findall ( tmp , value ) ]
split filter values split values by commas and quotes for in operator .