Send email notifications when a token becomes expired.

Review Request #12591 — Created Sept. 12, 2022 and submitted — Latest diff uploaded

Information

Review Board
release-5.0.x

Reviewers

Currently, users do not get notified about expired tokens. With this change, an
email is sent the first time an expired token is used. The email describes when
the token expired and how to create new tokens. If the email was successfully
sent, any subsequent uses of the token do not trigger another email.

This change also fixes up all of the API token email templates by adding date
formatting and fixing some missing URLs. The tests for the templates were also
fixed up.

  • Created unit tests for the expired token emails and ran unit tests in
    reviewboard/notifications/tests/test_email_sending.py
  • Manually tested authenticating with expired and non expired tokens, confirmed
    that appropriate emails were sent.

Changes between revision 5 and 6

orig
1
2
3
4
5
6

Commits

Summary ID Author
Send email notifications when a token becomes expired.
c67837f6476fa1c1d5feda35fbedc82aaffd57d8 Michelle Aubin
Send email notifications when a token becomes expired.
c776280c3483ba6eb35f95e8ca56cc0b603e4f3b Michelle Aubin
reviewboard/notifications/tests/test_email_sending.py
Loading...