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

Unified Diff: client/trace_inputs.py

Issue 1233303003: Migrate and merge logging_utils from swarming_bot into client/utils. (Closed) Base URL: git@github.com:luci/luci-py.git@master
Patch Set: Changed formatter Created 5 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: client/trace_inputs.py
diff --git a/client/trace_inputs.py b/client/trace_inputs.py
index 2ce64f497c2238a845a6254f72b10b5f9a888b60..47f798b72b127f656879b5a5e35c80ff7f12153b 100755
--- a/client/trace_inputs.py
+++ b/client/trace_inputs.py
@@ -39,6 +39,7 @@ from third_party.depot_tools import fix_encoding
from third_party.depot_tools import subcommand
from utils import file_path
+from utils import logging_utils
from utils import tools
## OS-specific imports
@@ -3353,7 +3354,7 @@ def CMDread(parser, args):
return 0
-class OptionParserTraceInputs(tools.OptionParserWithLogging):
+class OptionParserTraceInputs(logging_utils.OptionParserWithLogging):
"""Adds automatic --log handling."""
# Disable --log-file options since both --log and --log-file options are
@@ -3362,7 +3363,7 @@ class OptionParserTraceInputs(tools.OptionParserWithLogging):
enable_log_file = False
def __init__(self, **kwargs):
- tools.OptionParserWithLogging.__init__(self, **kwargs)
+ logging_utils.OptionParserWithLogging.__init__(self, **kwargs)
self.add_option(
'-l', '--log', help='Log file to generate or read, required')
@@ -3371,7 +3372,7 @@ class OptionParserTraceInputs(tools.OptionParserWithLogging):
On Windows, / and \ are often mixed together in a path.
"""
- options, args = tools.OptionParserWithLogging.parse_args(
+ options, args = logging_utils.OptionParserWithLogging.parse_args(
self, *args, **kwargs)
if not options.log:
self.error('Must supply a log file with -l')

Powered by Google App Engine
This is Rietveld 408576698