Autolabel group label on MRs based on author group information from team.yml
requested to merge 141-autolabel-group-label-on-mrs-based-on-author-group-information-from-team-yml into master
This MR changes the following:
- Adds a new pre-hygiene job
label-merge-request-author-group
to label MR based on author's group - The label inference in
stage-and-group-labels-hygiene
for Merge Request is updated to follow the following table, in order to account for MR author's group. The rows marked with * are new behaviour introduced in this MR. Others follow the status quo.
# | has_stage_label? | has_group_label? | has_category_labels? | group_is_part_of_stage? | inference_strategy |
---|---|---|---|---|---|
1 | true | true | true | N.A | Not needed |
2 | true | true | false | true | infer category from group |
3 * | true | true | false | false | do not infer category |
4 | true | false | true | N.A | infer group from stage |
5 | true | false | false | N.A | infer group from stage |
6 * | false | true | true | N.A | do not infer stage |
7 * | false | true | false | N.A | do not infer stage and category |
8 | false | false | true | N.A | do not infer stage and group |
9 | false | false | false | N.A | Not possible |
Caveat:
- MRs that have legacy team labels (with
[DEPRECATED]
) would follow the status quo inference which uses the legacy team labels.
default-labels
scheduled pipeline https://gitlab.com/gitlab-org/quality/triage-ops/pipelines/114386031
policies/stages/pre-hygiene/label-merge-request-author-group.yml
on gitlab-org
https://gitlab.com/gitlab-org/quality/triage-ops/-/jobs/423438974 result looks good.
For reference and comparison, status quo default-labels
pipeline: https://gitlab.com/gitlab-org/quality/triage-ops/pipelines/114388839
Follow up issues:
-
✅ #402 (closed) Comment if MR author group cannot be determined !390 (comment 278719721)
Consider adding documentation to the handbook pages for Triage Operations when creating a new triage policy or triage package:
Closes #141 (closed)
Edited by Albert Salim