Log¶
Logger tool
To use logger in your module (action, authentication backend, sms engine), you can declare log variable as global and use it anywhere in your code:
from janua.utils.logger import getLogger
log = getLogger(__name__)
log.debug('Module %s loaded' % __name__)
# special case for critical log, it send a mail report to administrator
log.critical('Something goes wrong')