import logging


def logger(request):
    """Sets up a logger at loglevel 1 and attaches a LogHandler."""
    logger_ = logging.getLogger(request.function.__name__)
    logger_.setLevel(1)
    return logger_