WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
57250
check-webkit-style confused by two ChangeLog entries in a row from same user
https://bugs.webkit.org/show_bug.cgi?id=57250
Summary
check-webkit-style confused by two ChangeLog entries in a row from same user
Jeff Miller
Reported
2011-03-28 11:03:53 PDT
Earlier today, in
r82114
, I checked in a rubber-stamped change to WebKitLibraries without a bug number in WebKitLibraries/ChangeLog. Then, I uploaded a patch for <
https://bugs.webkit.org/show_bug.cgi?id=57195
> at 2011-03-28 10:45 PST which also included a change to WebKitLibraries (with a bug number in the ChangeLog). However, check-webkit-style failed on WebKitLibraries/ChangeLog for the patch with: WebKitLibraries/ChangeLog:15: ChangeLog entry has no bug number [changelog/bugnumber] [5] I think it's confused by my earlier rubber-stamped ChangeLog entry.
Attachments
Patch
(15.86 KB, patch)
2011-03-29 01:03 PDT
,
David Levin
no flags
Details
Formatted Diff
Diff
Patch
(16.12 KB, patch)
2011-03-29 01:26 PDT
,
David Levin
no flags
Details
Formatted Diff
Diff
Patch
(16.18 KB, patch)
2011-03-29 09:10 PDT
,
David Levin
no flags
Details
Formatted Diff
Diff
Patch
(16.47 KB, patch)
2011-03-29 11:53 PDT
,
David Levin
no flags
Details
Formatted Diff
Diff
Show Obsolete
(3)
View All
Add attachment
proposed patch, testcase, etc.
David Levin
Comment 1
2011-03-28 11:33:09 PDT
Bummer I specifically got this added to the tests that went in with that change.
Jeff Miller
Comment 2
2011-03-28 13:08:48 PDT
I'm also seeing this with my patch for
https://bugs.webkit.org/show_bug.cgi?id=57262
Patrick R. Gansterer
Comment 3
2011-03-28 13:16:19 PDT
Hmmm, I don't see the reason for the false positive at the moment. I need to test this on my "WebKit machine". :-( Unfortunally I don't have time to look at this before tomorrow. I'll take care of this issue.
David Levin
Comment 4
2011-03-28 17:35:32 PDT
I know what is going wrong with one of them: 1. The diff came out "funny" due to the entries in succession. When the checker logs the error for line 15 (for the following entry which has no bug number). the error filter allows the error to go through because this line is in the diff. 2. For
bug 57262
, the checker was correct that the ChangeLog entry starting at line 13 had no bug number but line 13 was not part of the patch for the error filter should have removed this. We can fix these by limiting the lines given to the main check function to be just the added lines. (Of course, we'll have to adjust the lines where the errors are reported if this approach is taken.)
David Levin
Comment 5
2011-03-28 18:08:25 PDT
(In reply to
comment #4
)
> 2. For
bug 57262
, the checker was correct that the ChangeLog entry starting at line 13 had no bug number but line 13 was not part of the patch for the error filter should have removed this.
Ah. For this one it is the same problem as #1. Even though the patch doesn't show line 13 as being part of the patch, the patch is applied locally and when the diff is done locally, then the line 1 is not part of the diff but line 13 is.
David Levin
Comment 6
2011-03-29 01:03:51 PDT
Created
attachment 87279
[details]
Patch
Patrick R. Gansterer
Comment 7
2011-03-29 01:20:42 PDT
Comment on
attachment 87279
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=87279&action=review
LGTM
> Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:-43 > -
Hmmm, my style checker wanted this empty line before def.
> Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:79 > + ' Example bug' > + '\n'
\n into the same line
> Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:106 > def test_no_error(self):
Maybe you can add an empty one too
Eric Seidel (no email)
Comment 8
2011-03-29 01:24:19 PDT
Comment on
attachment 87279
[details]
Patch We ahve code for fixing up ChagneLog diffs somewehre. Seems check-webkit-style would only want to scan the current ChangeLog and ignore the rest of hte diff. (I haven't really looked at your patch, mabye that's what it does)
David Levin
Comment 9
2011-03-29 01:26:44 PDT
Created
attachment 87281
[details]
Patch
David Levin
Comment 10
2011-03-29 01:31:37 PDT
(In reply to
comment #8
)
> (From update of
attachment 87279
[details]
) > We ahve code for fixing up ChagneLog diffs somewehre. Seems check-webkit-style would only want to scan the current ChangeLog and ignore the rest of hte diff. (I haven't really looked at your patch, mabye that's what it does)
Yes basically it does only look at the current ChangeLog. (In reply to
comment #7
)
> (From update of
attachment 87279
[details]
) > > Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:-43 > > - > > Hmmm, my style checker wanted this empty line before def.
It still does. It doesn't complain about my patch because the error gets filtered out (due to it being a deleted line) -- tricky case. Thanks for noticing. Addressed the other two comments also.
Patrick R. Gansterer
Comment 11
2011-03-29 01:33:28 PDT
Comment on
attachment 87281
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=87281&action=review
> Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:89 > + '2011-01-01 Patrick Gansterer <
paroga@paroga.com
>\n' > + '\n Example bug' > + '\n
http://trac.webkit.org/changeset/12345\n
')
The other lines have the \n only at the end
> Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:111 > + self.assert_no_error([], > + '2011-01-01 Patrick Gansterer <
paroga@paroga.com
>\n' > + '\n' > + ' Example bug\n' > + '
http://bugs.webkit.org/show_bug.cgi?id=12345\n
')
Thx, maybe we can add and "invalid" entry with emty range too.
David Levin
Comment 12
2011-03-29 09:10:50 PDT
Created
attachment 87342
[details]
Patch
David Levin
Comment 13
2011-03-29 09:12:47 PDT
(In reply to
comment #11
)
> (From update of
attachment 87281
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=87281&action=review
> > > Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:89 > > + '2011-01-01 Patrick Gansterer <
paroga@paroga.com
(:paroga) (c)>\n' > > + '\n Example bug' > > + '\n
http://trac.webkit.org/changeset/12345\n
') > > The other lines have the \n only at the end
Fixed.
> > > Tools/Scripts/webkitpy/style/checkers/changelog_unittest.py:111 > > + self.assert_no_error([], > > + '2011-01-01 Patrick Gansterer <
paroga@paroga.com
(:paroga) (c)>\n' > > + '\n' > > + ' Example bug\n' > > + '
http://bugs.webkit.org/show_bug.cgi?id=12345\n
') > > Thx, maybe we can add and "invalid" entry with emty range too.
I don't understand because I think the lines which start with self.assert_error(2, range(2, 5), 'changelog/bugnumber' already do this.
Patrick R. Gansterer
Comment 14
2011-03-29 11:31:45 PDT
(In reply to
comment #13
)
> I don't understand because I think the lines which start with > self.assert_error(2, range(2, 5), 'changelog/bugnumber' > already do this.
I mean sth like the following: + self.assert_no_error([], + '2011-01-01 Patrick Gansterer <
paroga@paroga.com
>\n' + '\n' + ' Example ChangeLog entry out of range\n' + '
http://example.com/\n
')
David Levin
Comment 15
2011-03-29 11:53:28 PDT
Created
attachment 87381
[details]
Patch
David Levin
Comment 16
2011-03-29 11:53:55 PDT
(In reply to
comment #14
)
> (In reply to
comment #13
) > > I don't understand because I think the lines which start with > > self.assert_error(2, range(2, 5), 'changelog/bugnumber' > > already do this. > > I mean sth like the following:
ok. done.
Shinichiro Hamaji
Comment 17
2011-03-29 18:23:24 PDT
Comment on
attachment 87381
[details]
Patch Looks good.
WebKit Commit Bot
Comment 18
2011-03-29 19:01:21 PDT
Comment on
attachment 87381
[details]
Patch Clearing flags on attachment: 87381 Committed
r82382
: <
http://trac.webkit.org/changeset/82382
>
WebKit Commit Bot
Comment 19
2011-03-29 19:01:25 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug