Repository navigation
Conversation
Some members, such as mentors, don't need to fill in availability, but the reminder tagged them every day. The "unanswered" rule takes an optional list of exempt teams: anyone in one of them, or in its sub-teams, is never reminded and isn't counted. Who is a mentor stays in Keycloak: a mentors team can join them by role (auto-join roles), and each team's reminder picks it on the admin page. The field is optional in the rule's config, so saved rules keep working and no schema change is needed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 15, 2026
kennhung
reviewed
Nov 15, 2026
kennhung
left a comment
Member
There was a problem hiding this comment.
Looks good to me. Using teams (joined by Keycloak role) to decide who is exempt fits keeping the member system as the source of truth. Two minor notes inline.
This PR, #150 and #151 all touch team-reminder-dto.ts and its test, so expect a conflict resolution on whichever merges later. Suggested order: #150, #152, #151.
| }); | ||
| const exempt = settings.exemptTeamIds ?? []; | ||
| const toggleExempt = (id: string) => set({ | ||
| exemptTeamIds: teams.map(team => team.id).filter(teamId => (teamId === id) !== exempt.includes(teamId)), |
Member
There was a problem hiding this comment.
Two small things, neither blocking:
- Rebuilding the list from
teams.map(...)drops ids of deleted teams the first time any button is toggled. That is nice, but the PR description says they are not cleaned up, so the two should agree. - A team can pick its own parent here, which exempts every member of this team, so the reminder is always empty. Consider a hint or filtering ancestors out of the buttons.
Exempting this team or one of its ancestors makes every member exempt, so the reminder is always empty. The buttons now leave out the team itself and its ancestors. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
Thanks, both handled in 2ee245f.
Tests (336), |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Some members, such as mentors, don't need to fill in availability, but a team's reminder tags everyone in the team and its sub-teams who hasn't, every day. This lets a reminder skip members of chosen teams.
exemptTeamIdsis an optional field in the "unanswered" rule'sconfig(ObjectIds, deduped, at most 50), so rules saved before keep working and there is no schema change.Evidence
On a local preview with a real MongoDB, a Mentor team (one member of 機械組 also in it), and the parent team's reminder:
New tests:
tsc --noEmit, ESLint on the changed files andnpm run buildpass.Merge danger
Door: two-way. An optional config field; no schema change.
Blast radius: the team reminder settings and who gets reminded.
🤖 Generated with Claude Code