#NEWLINE# @ classmethod #NEWLINE# def remove_images_resp( cls , **kwargs ) : #NEWLINE# #INDENT# logger . info ( 'RPC method remove_images_resp received: %s' , jsonutils . dumps ( kwargs ) ) #NEWLINE# status = kwargs . get ( 'status' ) #NEWLINE# task_uuid = kwargs [ 'task_uuid' ] #NEWLINE# task = objects . Task . get_by_uuid ( task_uuid ) #NEWLINE# if ( status == consts . TASK_STATUSES . ready ) : #NEWLINE# #INDENT# logger . info ( 'IBP images from deleted cluster have been removed' ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( status == consts . TASK_STATUSES . error ) : #NEWLINE# #INDENT# logger . error ( 'Removing IBP images failed: task_uuid %s' , task_uuid ) #NEWLINE# #UNINDENT# #UNINDENT# objects . Task . update ( task , { #NEWLINE# #INDENT# 'status' : status , #NEWLINE# #UNINDENT# } )