def _wait_for_volume_state_change(operation, volume, update=_get_ebs_volume_state, timeout=VOLUME_STATE_CHANGE_TIMEOUT):
 time.sleep(5.0)
 start_time = time.time()
 poll_until((lambda : _reached_end_state(operation, volume, update, (time.time() - start_time), timeout)), itertools.repeat(1))

def _wait_for_volume_state_change ( operation , volume , update = _get_ebs_volume_state , timeout = VOLUME_STATE_CHANGE_TIMEOUT ) : time . sleep ( 5.0 ) start_time = time . time ( ) poll_until ( ( lambda : _reached_end_state ( operation , volume , update , ( time . time ( ) - start_time ) , timeout ) ) , itertools . repeat ( 1 ) )
helper function to wait for a given volume to change state from start_status via transient_status to end_status .