class_docstr: Contains lambda boto3 wrappers to Create, Update, Delete and Invoke Lambda functions.
class_docstr_tok: ["Contains","lambda","boto3","wrappers","to","Create",",","Update",",","Delete","and","Invoke","Lambda","functions","."]
docstr: Method to create a lambda function or update it if it already exists
  
  Returns: boto3 response from Lambda's methods.
docstr_tok: ["Method","to","create","a","lambda","function","or","update","it","if","it","already","exists","Returns",":","boto3","response","from","Lambda","'s","methods","."]
code: def upsert(self):
      """Method to create a lambda function or update it if it already exists
  
      Returns: boto3 response from Lambda's methods.
      """
      try:
          return self.create()
      except ValueError as error:
          if "ResourceConflictException" in str(error):
              return self.update()
          raise
  
file_path: sagemaker-python-sdk/src/sagemaker/lambda_helper.py
imports: from __future__ import print_function, absolute_import
  from io import BytesIO
  import zipfile
  import time
  from botocore.exceptions import ClientError
  from sagemaker import s3
  from sagemaker.session import Session
label_desc: Use image node_id 4 for calling the Lambda obj's underlying member method code with example usage: obj.upsert() and returns: self, self