-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use github wf to add module labels for PR based on file changes #14101
Conversation
This PR has not had activity in the past 2 weeks, labeling it as stale. If the PR is waiting for review, notify the [email protected] list. Thank you for your contribution! |
@pseudo-nymous, I'm only seeing this now, sorry! At first glance, it matches what I had in mind - thank you for addressing that issue! I'll do an in-depth review soon, but I'd appreciate others' thoughts as well. One potential concern is our GitHub action budget - do you have a sense of the cost of this workflow? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great @pseudo-nymous! I left minor comments that I would like to see addressed, but this is very good already. I retract my concern about the action budget. This is running when a PR is created or updated, which is not that often.
053f572
to
7974a76
Compare
Did further testing with new sync flag, change is working as expected. |
Thanks. Yes, this bot is only triggered when when pr is created or updated. I have addressed all the comments. Please take a look. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for responding to the comments so quickly! I've one more small thing to add and if that's sorted I'll leave it a few days to see if others have feedback, then merge.
Wow, this looks really awesome! I wish we could retroactively apply it to PRs missing their module labels ... but let's start with this change (so new PRs are labeled). |
Thank you for this contribution @pseudo-nymous, I merged it just now and I'm really looking forward to see the first PR using it! |
Thanks. I checked if same script could be used to label older PRs but there is no such event corresponding to already closed PR. |
Brilliant! Let us know if you find anything. If you're interesting in this area of GitHub workflows / community tools, there are a few others that would be great to do: |
I'll be happy to work on these. Thanks! |
I've seen new PRs get labels assigned. I like how it's working! |
Description
Adds a new bot to automate labelling of pull requests with module tags based on file changes.
This bot uses
.github/labeler.yml
file to maintain mapping for module labels to corresponding regex paths to track.This workflow is triggered using
pull_request_target
event which provides necessary write permission for adding labels to PRs. More details around this event: StackOverflowTesting
Tested changes by creating pr on my own fork. pseudo-nymous#2
Further testing with sync flag: pseudo-nymous#3
Closes #13897