#NEWLINE# def get_placeholders( template ) : #NEWLINE# #INDENT# compiled_template = get_template ( template ) #NEWLINE# placeholders = _scan_placeholders ( _get_nodelist ( compiled_template ) ) #NEWLINE# clean_placeholders = [ ] #NEWLINE# for placeholder in placeholders : #NEWLINE# #INDENT# if ( placeholder in clean_placeholders ) : #NEWLINE# #INDENT# warnings . warn ( 'Duplicate {{% placeholder "{0}" %}} in template {1}.' . format ( placeholder , template , placeholder ) , DuplicatePlaceholderWarning ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# validate_placeholder_name ( placeholder ) #NEWLINE# clean_placeholders . append ( placeholder ) #NEWLINE# #UNINDENT# #UNINDENT# return clean_placeholders