#NEWLINE# def resolve_columns( self , row , fields = ( ) ) : #NEWLINE# #INDENT# values = [ ] #NEWLINE# index_extra_select = len ( self . query . extra_select ) #NEWLINE# for ( value , field ) in zip_longest ( row [ index_extra_select : ] , fields ) : #NEWLINE# #INDENT# if ( field and ( field . get_internal_type ( ) in ( 'BooleanField' , 'NullBooleanField' ) ) and ( value in ( 0 , 1 ) ) ) : #NEWLINE# #INDENT# value = bool ( value ) #NEWLINE# #UNINDENT# values . append ( value ) #NEWLINE# #UNINDENT# return ( row [ : index_extra_select ] + tuple ( values ) )