Skip to content
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

Generated dashboard tags for PR group assignment status #178

Open
gregr-ni opened this issue Jan 11, 2022 · 2 comments
Open

Generated dashboard tags for PR group assignment status #178

gregr-ni opened this issue Jan 11, 2022 · 2 comments

Comments

@gregr-ni
Copy link

Problem

The Required tag on the PR dashboard works great for individuals. It would be great to have similar functionality for the group case. When a group is assigned as a reviewer, I can create a dashboard section to show PRs assigned to that group. The problem is that the section does not distinguish between PRs that have already been approved by someone in the group and PRs that have not. As a representative of the group, I can’t tell which ones still need action from me and which ones don’t.

Proposed solution

Generate a "Required" tag when a PR requires a group that the user is in and no one in that group has approved.

@alejandro5042
Copy link
Owner

Thank you for this suggestion! The problem and proposed solution make total sense.

The implementation wouldn't be too hard, yet would require at least one API call to determine if the user is in a group that hasn't voted, per group. Since groups can contain other groups, it could be many more. This could make the page really slow, especially if you are in a network starved location. Or maybe not -- it depends on how many PRs/groups/sections you have. Not against doing it though to find out. And we can also cache calls for a short time.

Since you noted to me internally that you are waiting to see if it is a problem, once you confirm it would be useful, I'll put it on the docket to implement next.

@gregr-ni
Copy link
Author

I think it is likely to be a problem.

We don't necessarily need to know membership if we can know the group in a different way. What I care about is sections configured to show PRs assigned to a specific group. I don't see any easy way from the info in the page to detect that. Is there a straightforward way to get that?

If we can't deduce it, we could require the user to help by using a specific format for the section title. We could define a format like "Assigned to Group Name" or "{Group Name}" in the title to provide the group name. Then we could ignore membership and just generate a tag based on whether that group is satisfied or not. To make this distinct from the "Required" tag we could use the group name as the tag. It could be red for still needed and green or not present if already satisfied.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants