def METHOD_NAME(date="(unknown)"):
    "Raises an assertion or sends traceback to admins if executed."
    frame = inspect.currentframe().f_back
    if settings.DEBUG is True or settings.SERVER_MODE == 'test':
        raise AssertionError("Arrived at code in %s() which was marked unreachable on %s." % (frame.f_code.co_name, date))
    else:
        # build a simulated traceback object
        tb = build_traceback(inspect.stack()[1:])
        # provide extra info if available
        extra = {}
        for key in [ 'request', 'status_code', ]:
            if key in frame.f_locals:
                extra[key] = frame.f_locals[key]
        logger.error("Arrived at code in %s() which was marked unreachable on %s." % (frame.f_code.co_name, date),
                        exc_info=(AssertionError, None, tb), extra=extra)