This is an archive of the discontinued LLVM Phabricator instance.

github: Add action for automated issue notification
ClosedPublic

Authored by tstellar on Nov 22 2021, 8:47 PM.

Details

Summary

This adds a github action that will mention a team called issue-subscribers-$LABEL
whenever a label is added to a bug. Mentioning the team will automatically
subscribe all team members to the bug.

Diff Detail

Event Timeline

tstellar requested review of this revision.Nov 22 2021, 8:47 PM
tstellar created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptNov 22 2021, 8:47 PM
asl added a comment.Dec 13 2021, 9:52 AM

@tstellar Does it work for our "complex" labels? E.g. "lld:ELF" or "tools:llvm-ar/llvm-ranlib"?

Presumably we can generate the team memberships from the Bugzilla component auto-subscribers easily enough, even if it's manual.
I take it we'd need one of these sub-teams per label (mostly); is there a max number of teams?

(I don't know anything about GH actions, this is responding to the high-level description not the implementation.)

keith added a subscriber: keith.Dec 13 2021, 10:29 AM
tstellar updated this revision to Diff 394018.Dec 13 2021, 12:57 PM

Add support for labels with colons in name.

tstellar updated this revision to Diff 394020.Dec 13 2021, 1:07 PM

Rename script to issue-subscriber.
Add support for labels with /.

@tstellar Does it work for our "complex" labels? E.g. "lld:ELF" or "tools:llvm-ar/llvm-ranlib"?

I updated the patch to handle these cases.

Presumably we can generate the team memberships from the Bugzilla component auto-subscribers easily enough, even if it's manual.

Yes, we can do that.

I take it we'd need one of these sub-teams per label (mostly); is there a max number of teams?

I'm not aware of a limit on the number of teams.

(I don't know anything about GH actions, this is responding to the high-level description not the implementation.)

keith added a comment.Dec 13 2021, 3:06 PM

I take it we'd need one of these sub-teams per label (mostly); is there a max number of teams?

For reference I am in a github org with ~6k teams without issue.

alexbatashev requested changes to this revision.Dec 14 2021, 8:01 AM
alexbatashev added a subscriber: alexbatashev.
alexbatashev added inline comments.
.github/workflows/issue-subscriber.yml
12

Could you please apply fix from https://reviews.llvm.org/D115708 here as well?

This revision now requires changes to proceed.Dec 14 2021, 8:01 AM
tstellar updated this revision to Diff 394275.Dec 14 2021, 8:41 AM

Disable action for forks.

tstellar marked an inline comment as done.Dec 14 2021, 8:42 AM
alexbatashev resigned from this revision.Dec 14 2021, 8:50 AM

Thanks a lot, @tstellar!

I think this would be useful to have, as writing fine-grained filter rules is not necessarily easy or even doable in some mail clients, such as gmail.
With that in mind, I wonder if this action (which if I understand correctly will add a comment mentioning "@issue-subscribers-label"), results in the corresponding notification email adding "issue-subscribes-label@noreply.github.com"? I hope it does as that probably would make it easier to write email filters.

The only other thought I have here is if any other github projects have similar notification issues and if there is a de facto standard amongst such project on how to solve that?

Ping on this issue? We're really missing on the auto-subscribe that Bugzilla was offering :(

This revision was not accepted when it landed; it landed in state Needs Review.Jan 5 2022, 10:36 AM
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.