Reorganize rebaseline commands so that there's one command per module. |
||||||||
Issue description
Currently all of the rebasing-related commands are in one file, webkitpy/tool/commands/rebaseline.py. Current class tree:
Command
AbstractRebaseliningCommand
BaseInternalRebaselineCommand
CopyExistingBaselinesInternal
RebaselineTest
AbstractRebaseliningCommand
AnalyzeBaselines
AbstractParallelRebaselineCommand
RebaselineJson
RebaselineExpectations
Rebaseline
AutoRebaseline
It maybe easier to navigate the code if there's one class per file, and if the files have slightly clearer names. Proposal:
1. Merge BaseInternalRebaselineCommand and AbstractRebaseliningCommand to make a base class (BaseInternalRebaselineCommand doesn't contain much now) called AbstractRebaselineCommand.
2. Rename some classes. Possible renaming:
RebaselineTest -> RebaselineSingleTest
CopyExistingBaselinesInternal -> CopyExistingBaselines
Rebaseline -> RebaselineMultipleTests?
3. Split classes into separate files, e.g.:
abstract_rebaseline_command.py
rebaseline_single_test.py
analyze_baselines.py
optimize_baselines.py
...
Also, somewhat relatedly, maybe AnalyzeBaselines, OptimizeBaselines, and CopyExistingBaselines might not need to be subclasses of AbstractRebaselineCommand.
,
Jul 26 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/659666a1742a7bb0100111ad8a9dbae917407d36 commit 659666a1742a7bb0100111ad8a9dbae917407d36 Author: qyearsley <qyearsley@chromium.org> Date: Tue Jul 26 23:53:11 2016 Split out optimize-baselines command from rebaseline.py. BUG=616967 Review-Url: https://codereview.chromium.org/2128233003 Cr-Commit-Position: refs/heads/master@{#407979} [add] https://crrev.com/659666a1742a7bb0100111ad8a9dbae917407d36/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines.py [add] https://crrev.com/659666a1742a7bb0100111ad8a9dbae917407d36/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines_unittest.py [modify] https://crrev.com/659666a1742a7bb0100111ad8a9dbae917407d36/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py [modify] https://crrev.com/659666a1742a7bb0100111ad8a9dbae917407d36/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline_unittest.py [modify] https://crrev.com/659666a1742a7bb0100111ad8a9dbae917407d36/third_party/WebKit/Tools/Scripts/webkitpy/tool/webkit_patch.py
,
Aug 2 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/457cf9a342bcc2673caaf99b12b4ea5412e225e7 commit 457cf9a342bcc2673caaf99b12b4ea5412e225e7 Author: qyearsley <qyearsley@chromium.org> Date: Tue Aug 02 17:28:45 2016 Extract AutoRebaseline out of rebaseline.py. BUG=616967 Review-Url: https://codereview.chromium.org/2191423003 Cr-Commit-Position: refs/heads/master@{#409220} [add] https://crrev.com/457cf9a342bcc2673caaf99b12b4ea5412e225e7/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/auto_rebaseline.py [add] https://crrev.com/457cf9a342bcc2673caaf99b12b4ea5412e225e7/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/auto_rebaseline_unittest.py [modify] https://crrev.com/457cf9a342bcc2673caaf99b12b4ea5412e225e7/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py [modify] https://crrev.com/457cf9a342bcc2673caaf99b12b4ea5412e225e7/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline_unittest.py [modify] https://crrev.com/457cf9a342bcc2673caaf99b12b4ea5412e225e7/third_party/WebKit/Tools/Scripts/webkitpy/tool/webkit_patch.py
,
Aug 24 2016
,
Sep 21 2016
,
Oct 21 2016
,
Oct 27 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/3078bc85c2b7d7f8feddd8d19b7a11e2fbed9d90 commit 3078bc85c2b7d7f8feddd8d19b7a11e2fbed9d90 Author: qyearsley <qyearsley@chromium.org> Date: Thu Oct 27 22:14:09 2016 Refactoring in rebaseline.py: Combine BaseInternalRebaselineCommand and AbstractRebaseliningCommand. Reason: this simplifies the class hierarchy. BUG=616967 Review-Url: https://codereview.chromium.org/2451243002 Cr-Commit-Position: refs/heads/master@{#428159} [modify] https://crrev.com/3078bc85c2b7d7f8feddd8d19b7a11e2fbed9d90/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py
,
Apr 6 2017
Update: I'm still planning to do this, although it's still low-priority.
,
Jun 1 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99 commit 4b31acdd37eb70ad84fbd68a03ee2e66acb93f99 Author: Quinten Yearsley <qyearsley@google.com> Date: Thu Jun 01 22:51:22 2017 Extract "internal" rebaseline commands to separate files. This is a continuation of changes in http://crbug.com/616967; the purpose is to make it so that in general there's one class per file, and files aren't too large. This CL also makes a couple of minor clean-up changes in the classes that are moved, e.g. changing method order, but this CL doesn't include any changes to behavior. Bug: 616967 Change-Id: I4f6aade879d0f660d3f35668448028e8ef0651b0 Reviewed-on: https://chromium-review.googlesource.com/521787 Commit-Queue: Quinten Yearsley <qyearsley@chromium.org> Reviewed-by: Xianzhu Wang <wangxianzhu@chromium.org> Cr-Commit-Position: refs/heads/master@{#476465} [add] https://crrev.com/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/copy_existing_baselines.py [add] https://crrev.com/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/copy_existing_baselines_unittest.py [modify] https://crrev.com/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline.py [add] https://crrev.com/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline_test.py [add] https://crrev.com/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline_test_unittest.py [modify] https://crrev.com/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/rebaseline_unittest.py [modify] https://crrev.com/4b31acdd37eb70ad84fbd68a03ee2e66acb93f99/third_party/WebKit/Tools/Scripts/webkitpy/tool/webkit_patch.py
,
Jul 20 2017
Tasks still left here:
Extract the following classes out of rebaseline.py:
AbstractRebaseliningCommand
AbstractParallelRebaselineCommand
RebaselineExpectations
TestBaselineSet
Related refactoring task: get rid of ChangeSet.
,
Aug 23 2017
,
Aug 24
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue. Sorry for the inconvenience if the bug really should have been left as Available. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Sep 24
Remaining work described in #10. |
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by bugdroid1@chromium.org
, Jun 3 2016