summaryrefslogtreecommitdiffstats
path: root/tools/python/google/logging_utils.py
diff options
context:
space:
mode:
authormaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-03-05 12:46:38 +0000
committermaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-03-05 12:46:38 +0000
commitf0a51fb571f46531025fa09240bbc3e1af925e84 (patch)
tree558b4f0e737fda4b9ab60f252c9c23b8a4ca523e /tools/python/google/logging_utils.py
parent6390be368205705f49ead3cec40396519f13b889 (diff)
downloadchromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.zip
chromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.tar.gz
chromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.tar.bz2
Fixes CRLF and trailing white spaces.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10982 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/python/google/logging_utils.py')
-rw-r--r--tools/python/google/logging_utils.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/python/google/logging_utils.py b/tools/python/google/logging_utils.py
index 673097b..5fd95d3 100644
--- a/tools/python/google/logging_utils.py
+++ b/tools/python/google/logging_utils.py
@@ -26,11 +26,11 @@ class StdoutStderrHandler(logging.Handler):
sys.stdout
'''
logging.Handler.__init__(self)
- self._err = logging.StreamHandler(err)
+ self._err = logging.StreamHandler(err)
self._out = logging.StreamHandler(out)
self._threshold = threshold
self._last_was_err = False
-
+
def setLevel(self, lvl):
logging.Handler.setLevel(self, lvl)
self._err.setLevel(lvl)
@@ -62,17 +62,17 @@ class StdoutStderrHandler(logging.Handler):
FORMAT = "%(asctime)s %(filename)s [%(levelname)s] %(message)s"
DATEFMT = "%H:%M:%S"
-def config_root(level=logging.INFO, threshold=logging.WARNING, format=FORMAT,
+def config_root(level=logging.INFO, threshold=logging.WARNING, format=FORMAT,
datefmt=DATEFMT):
''' Configure the root logger to use a StdoutStderrHandler and some default
- formatting.
+ formatting.
Args:
level: messages below this level are ignored
threshold: below this logging level messages are sent to stdout,
otherwise they are sent to stderr
format: format for log messages, see logger.Format
datefmt: format for date in log messages
-
+
'''
# to set the handler of the root logging object, we need to do setup
# manually rather than using basicConfig