fix: remove admin summary from emails sent counter#1749
Merged
Conversation
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:
This pull request improves the accuracy of notification delivery statistics by ensuring that admin summary emails (
admin.event_summary) are excluded from delivery counts, as including them could mislead administrators. It also introduces a dedicated test to verify this behavior.Notification delivery statistics improvements:
_aggregate_delivery_statsfunction indispatch_monitor.pyto excludeadmin.event_summarynotifications from delivery statistics by joining withNotificationEventand filtering out those with theADMIN_EVENT_SUMMARYtype. [1] [2]Testing enhancements:
TestAggregateDeliveryStatstest case intest_dispatch_notifications.pyto ensure that admin summary deliveries are not counted in delivery statistics, including setup and teardown logic for test isolation._aggregate_delivery_statsfunction into the test module for direct testing.Expected behavior:
Explain and/or show screenshots for how you expect the pull request to work in your testing (in case other devices exhibit different behavior).
Testing tips:
Provide tips, procedures and sample files on how to test the feature.
Testers are invited to follow the tips AND to try anything they deem relevant outside the bounds of the testing tips.
Please make sure these boxes are checked before submitting your pull request - thanks!
./scripts/api-tests.shto make sure you didn't break anything