annotate lib/logsetup.py @ 1239:0bc41be76de7
log reads in a more n3-like format for easier pasting
Ignore-this: 1a0027d4c65c5212398afc10121ea6c0
darcs-hash:c7ec51be0d3ba6c6f1047b3b9b5a7547e2a8d62b
author |
drewp <drewp@bigasterisk.com> |
date |
Sat, 13 Apr 2019 20:22:05 -0700 |
parents |
e379b1b4fe8b |
children |
|
rev |
line source |
806
|
1 # todo: graylog, twisted web route to some channel
|
|
2
|
|
3 import logging
|
|
4 logging.basicConfig(format="%(created)f %(asctime)s %(name)s %(levelname)s %(message)s")
|
|
5 logging.getLogger('restkit.client').setLevel(logging.WARN)
|
|
6 log = logging.getLogger()
|
|
7 log.setLevel(logging.INFO)
|
1022
|
8
|
|
9 def enableTwistedLog():
|
|
10 from twisted.python import log as twlog
|
|
11 import sys
|
|
12 twlog.startLogging(sys.stdout)
|
|
13
|
|
14
|
|
15
|