There was an error while loading. Please reload this page.
Get the name of the function last called.
Returns:
str
None.
import traceback from incendium import constants, exceptions from incendium.exceptions import ApplicationError def failed_function(): try: raise ValueError("Value Error.") except ValueError as exc: # An error occurred. message = constants.UNEXPECTED_ERROR.format( exceptions.get_function_name(), "\n".join(traceback.format_exc().splitlines()), ) raise ApplicationError(message, exc, exc.cause)