#NEWLINE# def render_next_step( self , form , **kwargs ) : #NEWLINE# #INDENT# '\n        In the validation step, ask the device to generate a challenge.\n        ' #NEWLINE# next_step = kwargs . steps . next #NEWLINE# if ( next_step == 'validation' ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# self . get_device ( ) . generate_challenge ( ) #NEWLINE# kwargs [ 'challenge_succeeded' ] = True #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# logger . exception ( 'Could not generate challenge' ) #NEWLINE# kwargs [ 'challenge_succeeded' ] = False #NEWLINE# #UNINDENT# #UNINDENT# return super ( SetupView , self ) . render_next_step ( form , ** kwargs )