Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(269)

Side by Side Diff: client/third_party/infra_libs/logs/logs.py

Issue 2013943002: Changing license header, again! (Closed) Base URL: git@github.com:luci/luci-py.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # that can be found in the LICENSE file.
4 4
5 """Utilities for logging. 5 """Utilities for logging.
6 6
7 Example usage: 7 Example usage:
8 8
9 .. code-block:: python 9 .. code-block:: python
10 10
11 import argparse 11 import argparse
12 import logging 12 import logging
13 import infra_libs.logs 13 import infra_libs.logs
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
286 for level in file_levels: 286 for level in file_levels:
287 add_handler( 287 add_handler(
288 logger, 288 logger,
289 handler=logging.handlers.RotatingFileHandler( 289 handler=logging.handlers.RotatingFileHandler(
290 filename=os.path.join( 290 filename=os.path.join(
291 logs_directory, pattern % logging.getLevelName(level)), 291 logs_directory, pattern % logging.getLevelName(level)),
292 maxBytes=10 * 1024 * 1024, 292 maxBytes=10 * 1024 * 1024,
293 backupCount=10, 293 backupCount=10,
294 delay=True), 294 delay=True),
295 level=level) 295 level=level)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698