(retry_state: tenacity.RetryCallState)
Called after all retries failed.

  Simply outputs a message and re-raises.

  Args:
    retry_state: info about current retry invocation.

  Returns:
    None.
Called after all retries failed.
Called after all retries failed .
def on_give_up(retry_state: tenacity.RetryCallState) -> None:
  """Called after all retries failed.

  Simply outputs a message and re-raises.

  Args:
    retry_state: info about current retry invocation.

  Returns:
    None.
  """
  exception = retry_state.outcome.exception()
  attempt_number = retry_state.attempt_number
  _print_error('Giving up after {} attempts'.format(attempt_number))
  raise exception
def on_give_up ( retry_state : tenacity . RetryCallState ) -> None : exception = retry_state . outcome . exception ( ) attempt_number = retry_state . attempt_number _print_error ( 'Giving up after {} attempts' . format ( attempt_number ) ) raise exception