RESOLVED FIXED 72703
ChangeLog should be able to parse annotated changelogs
https://bugs.webkit.org/show_bug.cgi?id=72703
Summary ChangeLog should be able to parse annotated changelogs
Ryosuke Niwa
Reported 2011-11-18 01:44:52 PST
In order to parse change logs from different directories and correlate entries, we need a way to determine which change log entry corresponds to which revision.
Attachments
Patch (10.54 KB, patch)
2011-11-18 02:12 PST, Ryosuke Niwa
eric: review+
Ryosuke Niwa
Comment 1 2011-11-18 02:12:31 PST
WebKit Review Bot
Comment 2 2011-11-18 02:16:08 PST
Attachment 115770 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Tools/ChangeLog', u'Tools/Scripts/webkitpy..." exit_code: 1 Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:256: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:258: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:260: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:264: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:266: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:272: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:274: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:277: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:279: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:282: trailing whitespace [pep8/W291] [5] Tools/Scripts/webkitpy/common/checkout/changelog_unittest.py:286: trailing whitespace [pep8/W291] [5] Total errors found: 11 in 6 files If any of these errors are false positives, please file a bug against check-webkit-style.
Ryosuke Niwa
Comment 3 2011-11-18 02:18:50 PST
(In reply to comment #2) > If any of these errors are false positives, please file a bug against check-webkit-style. Indeed this is a false positive. The trailing space is required for svn blame format.
Ryosuke Niwa
Comment 4 2011-11-18 02:23:04 PST
Ryosuke Niwa
Comment 5 2011-11-18 12:06:00 PST
Ping reviewers.
Eric Seidel (no email)
Comment 6 2011-11-30 11:37:14 PST
Comment on attachment 115770 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=115770&action=review Looks good. > Tools/Scripts/webkitpy/common/checkout/changelog.py:287 > + most_probable_revision = max(revisions_in_entry, key=revisions_in_entry.__getitem__) if revisions_in_entry else None I'm not sure I understand this? Also, isn't there a getitem helper used for this sort of thing? Object.getitem orsoemthing? Maybe I'm thinking of operator.itemgetter?
David Levin
Comment 7 2011-11-30 15:07:32 PST
Comment on attachment 115770 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=115770&action=review > Tools/Scripts/webkitpy/common/checkout/changelog.py:247 > + def _sepearate_revision_and_line(line): fyi, typo: sepearate
Ryosuke Niwa
Comment 8 2011-12-02 20:53:43 PST
(In reply to comment #6) > (From update of attachment 115770 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=115770&action=review > > Looks good. > > > Tools/Scripts/webkitpy/common/checkout/changelog.py:287 > > + most_probable_revision = max(revisions_in_entry, key=revisions_in_entry.__getitem__) if revisions_in_entry else None > > I'm not sure I understand this? Also, isn't there a getitem helper used for this sort of thing? Object.getitem orsoemthing? Maybe I'm thinking of operator.itemgetter? Here, I'm taking the revision that appear most frequently as the guess.
Ryosuke Niwa
Comment 9 2011-12-02 20:54:08 PST
(In reply to comment #7) > (From update of attachment 115770 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=115770&action=review > > > Tools/Scripts/webkitpy/common/checkout/changelog.py:247 > > + def _sepearate_revision_and_line(line): > > fyi, typo: sepearate Will fix.
Ryosuke Niwa
Comment 10 2011-12-02 20:58:43 PST
Thanks for the review. Landing it now.
Ryosuke Niwa
Comment 11 2011-12-02 20:59:31 PST
Note You need to log in before you can comment on or make changes to this bug.