def mask_quotes(input):
 search_re = re.compile(('(.*?)' + QUOTE_RE_STR))
 return [search_re.sub(quote_replace, line) for line in input]

def mask_quotes ( input ) : search_re = re . compile ( ( '(.*?)' + QUOTE_RE_STR ) ) return [ search_re . sub ( quote_replace , line ) for line in input ]
mask the quoted strings so we skip braces inside quoted strings .