def s3_endpoint_for_region(region):
 region = _fix_region(region)
 if ((not region) or (region == _S3_REGION_WITH_NO_LOCATION_CONSTRAINT)):
  return _S3_REGIONLESS_ENDPOINT
 else:
  return (_S3_REGION_ENDPOINT % {'region': region})

def s3_endpoint_for_region ( region ) : region = _fix_region ( region ) if ( ( not region ) or ( region == _S3_REGION_WITH_NO_LOCATION_CONSTRAINT ) ) : return _S3_REGIONLESS_ENDPOINT else : return ( _S3_REGION_ENDPOINT % { 'region' : region } )
get the host for s3 in the given aws region .