def release_address(client, allocation_id, check_mode=False):
 err_msg = ''
 if check_mode:
  return (True, '')
 ip_released = False
 params = {'AllocationId': allocation_id}
 try:
  client.release_address(**params)
  ip_released = True
 except botocore.exceptions.ClientError as e:
  err_msg = str(e)
 return (ip_released, err_msg)

def release_address ( client , allocation_id , check_mode = False ) : err_msg = '' if check_mode : return ( True , '' ) ip_released = False params = { 'AllocationId' : allocation_id } try : client . release_address ( ** params ) ip_released = True except botocore . exceptions . ClientError as e : err_msg = str ( e ) return ( ip_released , err_msg )
release a previously allocated elastic ip address .