Stop logging authorized_teacher permissions to slack #20310
Merged
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.
This PR stops logging to slack when a teacher gets the 'authorized_teacher' permission. It also fixes the bug that logged each new permission to slack twice.
Over the last couple months, 1152 new user permissions have been created, of which 1123 were
authorized teacher
. Most of those were created in 5 large batches of ~200 teachers each:These batches of new permissions end up spamming the #infra-security room, making it very difficult for casual observers to spot unexpected permission changes as they scroll by. While it's good to have a log of permissions changes (perhaps we should send authorized_teacher changes to firehose instead?), the slack room is much more useful if we actually have the time to see everything that gets logged to it.