NEW 143965
webkit-patch should try harder to upload to the right bug when -b is not passed
https://bugs.webkit.org/show_bug.cgi?id=143965
Summary webkit-patch should try harder to upload to the right bug when -b is not passed
Michael Catanzaro
Reported 2015-04-20 14:12:29 PDT
I used the following command to upload a patch to Bugzilla for the commit prior to my HEAD (@): webkit-patch upload -g @^ The patch was uploaded to the wrong bug. It went to the bug specified in @ instead, even though that bug was not mentioned anywhere in the commit message or diff of @^. There was exactly one bug present in the commit diff (in a ChangeLog file); I would have expected the patch to be uploaded to that bug. The problem might be that Git.changed_files() in git.py seems to return the set of files changed SINCE the specified commit, rather than the set of files changed BY that commit (so none of the files changed in the commit are included). That seems confusing. AbstractPatchUploadingCommand._bug_id() in upload.py reasonably assumes it returns the files changed in that commit, which means -g will never pick the right bug except when using -g @. I've also noticed that webkit-patch post-commits is prone to choose wrong bugs, but that might be a separate issue.
Attachments
Michael Catanzaro
Comment 1 2015-04-20 14:50:20 PDT
(In reply to comment #0) > The problem might be that Git.changed_files() in git.py seems to return the > set of files changed SINCE the specified commit, rather than the set of > files changed BY that commit That was a bad guess. Git.merge_base() in git.py should transform the commit from @^ into @^^..@^ and that works as expected.
Note You need to log in before you can comment on or make changes to this bug.