Open ghassanmas opened 1 year ago
Thank you for your report! @openedx/axim-oncall will triage within a business day. Simple requests usually take 2-3 business days to resolve; more complex requests could take longer.
@ghassanmas it sounds like you want to add a reusable workflow to openedx/.github
, is the request here to make that change or to ask if it is okay to make that change, or something else?
@feanil I have some context on this (I asked Ghassan to file the request) and I'm on call this week, so I don't mind taking this one on.
@ghassanmas I have been thinking about this. It is useful to have actions available in every repo such as: backport
, assign me
, label:
etc. However, it becomes burdensome to add, remove, and update all these actions when each action requires a separate:
Furthermore, it will become hard for developers to remember how to trigger these actions if some of them are triggered by comments (assign me:
, label:
) and some of them are triggered by labels (backport
).
Here is my proposal.
backport: palm
.comment-listener.yml
. This shared workflow contains logic to handle all of the GitHub commands, including assign me
, label:
, remove-label:
, and anything else that we want to add in the future.comment-listener.yml
in order to add, remove, or change any command.Let me know what you think. If you like it, we can make this change, and backport:
could be the first new command added to comment-listener.yml
.
Hey folks apologies for the late reply.
I think there are two distinct suggestions:
First we create an extendable workflow, which would need only to be used /refs in all repo once, and when we want to add new command
, featuer
...etc we only need to change from openedx/.github
.
I indded agree with this, it would let us quickly create a new featuer/action.
I think in theory, it wouldn't matter if a developer flag their intent that this PR needs to be backported to master, via comment or a label. there are few points to consider though:
packport branch-name
and do the backport. @ghassanmas , I did not realize that in your workflow, the label causes the backport to be created only after the PR merges. That seems very helpful-- honestly a better UX than my comment-trigger proposal --because it lets people add the backport ...
label at any time, and not have to worry about remembering to backport later. It also has the added benefit that the backport action is already written. My bad for missing those details in your original proposal.
Given that, I think we should stick with your original label-trigger proposal. Let me know if you disagree.
In order to implement your proposal, you will need to:
EnsureWorkflowTemplates
, and overriding .workflow_templates
and .is_relevant()
so that it adds the correct workflow template to the correct repositories.(Regarding my comment-listener.yml
suggestion: I still would like to do that some day, but I don't think it is relevant to your proposal any more.)
@kdmccormick given that this work can now be self-service by making PRs and getting reviews on other repos, do you still need this ticket to track the work? Should it be closed or have the github-request
label removed?
It seems to me that this issue should be transferred to the .github
repo. I'll let @kdmccormick make that call though.
Firm Name
Zaatdev
Urgency
Low (2 weeks)
Problem/Request
We need a github action that would atuomate the process of creating a PR, I have tested this github action https://github.com/ghassanmas/edx-platform/blob/master/.github/workflows/backport.yml on my fork already.
My thinking is that this workflow would be added here https://github.com/openedx/.github/tree/master/.github/workflows with a spesfic name then it would be used on other repos as if it was imported openedx action/workflows. This is important because if in future we found somehting need to be changed about this workflow we wouldn't need to do X changes for X repos in openedx, and this tha pattern that currently exists for add-depre and label workflow.
Reasoning
Because we usually have many PRs to be backported to a release branch.