Repository navigation
Sachin/process per candidate - #1220
sachhayaKO wants to merge 3 commits into
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
|
[diff-counting] Significant lines: 10. |
zkdlinyne
left a comment
There was a problem hiding this comment.
hey sachin, thanks for implementing this! I couldn't test locally because no apps were submitted and I'm not really sure how to implement them but aside from that I just left one small comment about authorizedMembers being used as the list of leads.
Other than that all good code-wise!
| const userInfo = useSelf(); | ||
| const allLeads = useMembers().filter((member) => LEAD_ROLES.includes(member.role)); | ||
| // Count only the team's leads if an admin added them to this instance, otherwise all leads | ||
| const teamLeads = authorizedMembers.filter((member) => LEAD_ROLES.includes(member.role)); |
There was a problem hiding this comment.
hi sachin! This is small but I think if an admin adds one lead to authorizedMembers, countedLeads becomes only those leads (if that makes sense). I think it would be helpful to count every current lead and then stop using authorizedMembers as the lead list, since leads already have access to every instance. A normal instance has no leads on it, the count auto falls back to all leads.
Maybe keep allLeads from useMembers() and count a vote when LEAD_ROLES includes review.reviewer.role? In that case you could just remove the authorizedMembers prop.
Summary
Adds a per-candidate lead vote counter to the Candidate Decider so ops can track progress during delibs and know when to move on to the next candidate.
Notes
Setting up an instance for delibs: the total (Y in X/Y) is the number of leads added as authorized members when the instance is created at
/admin/candidate-decider.Ops/admins should add the leads who will actually be voting in that instance (e.g. that team's leads).