#NEWLINE# def describe_mismatch( self , item , desc ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# l = len ( item ) #NEWLINE# desc . append_text ( 'has {0} elements' . format ( l ) ) #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# desc . append_value ( item ) #NEWLINE# desc . append_text ( ' does not have a length' )