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
CI: include automatic Pull Request Labeler #10094
Conversation
Looks good, can we label it based on branch, too? |
Not with this one, it only analyzes paths of modified files. |
I also add this idea... but my idea was to create a bot with nodejs and host it instead of using actions |
Think he was referring to pr specific to openwrt release |
@Ansuel I'm fine with anything else but this solution exists now so why not use it till we have something more sophisticated? |
@pepe2k sure i wanted to put some comments just to get some feedback of my idea... But yhea ok for me for using actions to autolabel :D |
Do you have a working PoC or some similar solution available somewhere to look at? |
@pepe2k today i wasted some time with a PoC... (don't judge the following link ahahahah) https://github.com/Ansuel/test-openwrt-webook Anyway in practice my solution is a custom github app. Current implementation assume an issue with for example
where ath79 is parsed with a regex (everything before : is used), we search if a label exist with that and assign it. I also tested command. If you send a comment with /thanks the bot send a specific message. Tell me what do you think about this. (currently this is only implemented for issue but can be expanded and it's only a PoC) |
(i'm turning off the local server... put here a message and i will reopen it ASAP) |
And needs to be hosted/maintained by someone.
I'm focusing on PRs here only, not issues which are much more complicated and might require a sophisticated solution. I think this might not be reliable. You assume contributors will follow our patch submitting guide and provide correct prefixes - believe me, that's not always true. Solution based on a paths modified by commit/s in a selected PR is just simple and human-error prone. I also think a simple regex on PR/issue title for labeling can also be done with actions. Cheers, |
This is my concern... Anyway the bot is so easy that once done it doesn't require that much changes...
The example was with issue just because it was easier to create tons of issue to develop the bot. |
Whenever I hear something like this, I run away 😏
I still fail to understand and see why it's better? Cheers, |
|
LGTM as an immediate solution. My gripe of such solution is, that we need to have this file included in our source code repository, which is going to pollute Git log history with a commits which are not related to the source code and each such commit/modification then triggers a build pipeline on our buildbot and build firmware images for all targets (~24 hours), so wasting a lot of resources. Well, this is probably just an issue with our workflow and tooling around, so we should probably just start ignoring sole commits to a predefined directories like
FYI you can use scheduled GitHub Action for that purpose, which is essentially "serverless" cron job. I'm for example using such feature to self-assign patches on our patchwork, it's running every two hours and doesn't need any additional infrastructure.
You can enforce such formalities with GH Actions.
Well, on GitHub every pull request is an issue, but not every issue is a pull request, so they share a lot. Using templates to encourage useful issues and pull requests should help a lot as well. BTW GitLab is using machine learning for a classification based on a issue content. |
Also OK for me as a solution for now but IMHO we should use specialized tools instead of a simple labeler :D |
@pepe2k any news on this? |
@Ansuel I will rebase and look again into this in next days, thanks for reminder! |
8673da2
to
f5d48ff
Compare
Looks good. I'd merge this |
This adds GitHub CI action which makes use of 'Labeler', allowing automatic labeling of new PRs, based on the modified files paths. Below labels are supported and more can be added later: - 'target/*' - 'target/imagebuilder' - 'kernel' - 'core packages' - 'build/scripts/tools' - 'toolchain' - 'GitHub/CI' For more information: https://github.com/marketplace/actions/labeler Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
f5d48ff
to
6506864
Compare
This adds GitHub CI action which makes use of 'Labeler', allowing automatic labeling of new PRs, based on the modified files paths.
Below labels are supported and more can be added later:
For more information: https://github.com/marketplace/actions/labeler