Mercurial > code > home > repos > homeauto
view lib/logsetup.py @ 1022:e379b1b4fe8b
enableTwistedLog
Ignore-this: 75e28eaa4d1acc2db92144a0620eb9b8
darcs-hash:b3ee2f896f75ce1ba665772d32cbce4d4afc0bf1
author | drewp <drewp@bigasterisk.com> |
---|---|
date | Sun, 03 Jan 2016 02:28:44 -0800 |
parents | 85e50a597244 |
children |
line wrap: on
line source
# todo: graylog, twisted web route to some channel import logging logging.basicConfig(format="%(created)f %(asctime)s %(name)s %(levelname)s %(message)s") logging.getLogger('restkit.client').setLevel(logging.WARN) log = logging.getLogger() log.setLevel(logging.INFO) def enableTwistedLog(): from twisted.python import log as twlog import sys twlog.startLogging(sys.stdout)