aboutsummaryrefslogtreecommitdiff
path: root/gn3/debug.py
blob: acc24027efec830cf000c55f1b4c15cfd10ed148 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
"""Debug utilities"""
import logging
from flask import current_app

logger = logging.getLogger(__name__)

def __pk__(*args):
    value = args[-1]
    title_vals = " => ".join(args[0:-1])
    current_app.logger.setLevel(logging.DEBUG) # Force debug level since we assume we are using it!
    current_app.logger.debug("%s: %s", title_vals, value)
    return value