code: def auto_abort(exceptions):
      def outer(function):
          def inner(*args, **kwargs):
              try:
                  return function(*args, **kwargs)
              except exceptions as ex:
                  abort(400, error=ex)
              except Exception as ex:
                  LOGGER.exception("Uncontrolled Exception Caught")
                  abort(500, error=ex)
  
          return inner
  
      return outer
  
imports: import logging
  import os
  import traceback
  import flask
label_desc: Use image node_id 3 for calling a global function with example usage: auto_abort(exceptions) and returns: outer, inner, function