RFR: 1797: Add support for /backport pull request command

David Holmes david.holmes at oracle.com
Fri Feb 3 02:09:34 UTC 2023

On 3/02/2023 11:48 am, David Holmes wrote:
> On 2/02/2023 9:33 pm, Erik Duveblad wrote:
>>> On 2 Feb 2023, at 09:28, Thomas Stüfe <thomas.stuefe at gmail.com> wrote:
>>>> 1. If the `/backport` command is used in an **open** pull request, 
>>>> it adds a label `Backport=repo:branch` to the PR. If the PR is later 
>>>> integrated, the PR bot scans for backport labels and begins the 
>>>> backporting process. To cancel the backport, the user can use 
>>>> `/backport disable repo master` to remove the label before the PR is 
>>>> integrated.
>>> This does not sound desirable. Fixes should undergo some bake time in
>>> the primary repo before they get backported anywhere. With the current
>>> situation it is up to the person doing the backport to go to the commit
>>> in question and know that the commit has been suitable tested/baked.
>>> David
>>> -----
>>> I agree with David. Making it easy to downport fresh changes right 
>>> away is not something we should encourage.
>> Please do not jump to conclusions about what Zhao is proposing without 
>> understanding the patch :) Zhao’s patch is only making it easier to 
>> create a backport _pull request_, it will not automatically create any 
>> backport commits.
> Okay I misconstrued what "begins the backporting process" actually 
> meant. Sorry for the false alarm.
>> A user can already today type `/backport` in a commit comment for
>> the commit a pull request resulted in once it was integrated. This can be
>> done only seconds after the pull request was integrated and the Skara
>> bots will then go ahead and create a “backport pull request” (see the
>> Skara wiki on backports for more details [0]). Zhao’s patch only removes
>> the manual step of having to navigate to the GitHub page for the
>> resulting commit and add a commit comment. With Zhao’s patch a user can
>> now instead type `/backport` in the pull request and the Skara bots will
>> create the “backport pull request” once the pull request has been
>> integrated.
> Sure. And I understand better this isn't really trying to allow (though 
> it does) the ability to type:
> /integrate
> /backport ...
> in a PR but more dealing with the common(?) problem that when someone 
> does decide to backport a change they tend to go to the JBS issue, see 
> the PR link, go to the PR and type "/backport ..." only to be told they 
> are in the wrong place and need to go to the commit. I know I've done it 
> myself :)

Though that said, there really isn't any motivating usecase I can see 
for allowing /backport in an open PR.


> Cheers,
> David
> -----
>> So, this patch is not creating any new workflows, it is just removing 
>> a couple of manual steps needed today to create a "backport pull 
>> request". The "backport pull request" should of course not be 
>> integrated until the commit in mainline has received proper “soak 
>> time” and testing.
>> Thanks,
>> Erik
>> [0]: https://wiki.openjdk.org/display/SKARA/Backports

More information about the skara-dev mailing list