#NEWLINE# def instance_update_from_api( self , message , instance , expected_vm_state , expected_task_state , admin_state_reset ) : #NEWLINE# #INDENT# 'Update an instance in this cell.' #NEWLINE# if ( not expected_task_state ) : #NEWLINE# #INDENT# instance . obj_reset_changes ( [ 'vm_state' , 'task_state' ] ) #NEWLINE# #UNINDENT# instance . obj_reset_changes ( [ 'metadata' , 'system_metadata' ] ) #NEWLINE# with instance . skip_cells_sync ( ) : #NEWLINE# #INDENT# instance . save ( expected_vm_state = expected_vm_state , expected_task_state = expected_task_state )