MCPcopy Index your code
hub / github.com/zappa/Zappa / lambda_handler

Method lambda_handler

zappa/handler.py:289–304  ·  view source on GitHub ↗
(cls, event, context)

Source from the content-addressed store, hash-verified

287
288 @classmethod
289 def lambda_handler(cls, event, context): # pragma: no cover
290 handler = global_handler or cls()
291 exception_handler = handler.settings.EXCEPTION_HANDLER
292 try:
293 return handler.handler(event, context)
294 except Exception as ex:
295 exception_processed = cls._process_exception(
296 exception_handler=exception_handler,
297 event=event,
298 context=context,
299 exception=ex,
300 )
301 if not exception_processed:
302 # Only re-raise exception if handler directed so. Allows handler to control if lambda has to retry
303 # an event execution in case of failure.
304 raise
305
306 @classmethod
307 def _process_exception(cls, exception_handler, event, context, exception):

Callers 2

lambda_handlerFunction · 0.80

Calls 2

handlerMethod · 0.80
_process_exceptionMethod · 0.80

Tested by 1