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

Unified Diff: third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py

Issue 2014063002: Run format-webkit on webkitpy code (without string conversion). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py
diff --git a/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py b/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py
index c0f68026d184fd17c6e11b717cf2cbc43e4c3cdb..ee6773d893d2df62977cfdedaff4bd56a0e6988a 100644
--- a/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py
+++ b/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py
@@ -57,6 +57,7 @@ def _baseline_name(fs, test_name, suffix):
class AbstractRebaseliningCommand(Command):
+
"""Base class for rebaseline-related commands."""
# Not overriding execute() - pylint: disable=abstract-method
@@ -84,6 +85,7 @@ class AbstractRebaseliningCommand(Command):
class BaseInternalRebaselineCommand(AbstractRebaseliningCommand):
+
"""Base class for rebaseline-related commands that are intended to be used by other commands."""
# Not overriding execute() - pylint: disable=abstract-method
@@ -322,6 +324,7 @@ class AnalyzeBaselines(AbstractRebaseliningCommand):
class AbstractParallelRebaselineCommand(AbstractRebaseliningCommand):
+
"""Base class for rebaseline commands that do some tasks in parallel."""
# Not overriding execute() - pylint: disable=abstract-method
@@ -838,7 +841,7 @@ class AutoRebaseline(AbstractParallelRebaselineCommand):
last_output_time = time.time()
# git cl sometimes completely hangs. Bail if we haven't gotten any output to stdout/stderr in a while.
- while process.poll() == None and time.time() < last_output_time + self.SECONDS_BEFORE_GIVING_UP:
+ while process.poll() is None and time.time() < last_output_time + self.SECONDS_BEFORE_GIVING_UP:
# FIXME: This doesn't make any sense. readline blocks, so all this code to
# try and bail is useless. Instead, we should do the readline calls on a
# subthread. Then the rest of this code would make sense.
@@ -847,7 +850,7 @@ class AutoRebaseline(AbstractParallelRebaselineCommand):
last_output_time = time.time()
_log.info(out)
- if process.poll() == None:
+ if process.poll() is None:
_log.error('Command hung: %s' % subprocess_command)
return False
return True

Powered by Google App Engine
This is Rietveld 408576698