Skip to content

Conversation

@marius-mather
Copy link
Collaborator

@marius-mather marius-mather commented Dec 19, 2025

Description

AAI-558: sync email verification status more frequently so there is less inconsistency between Auth0 and our database.

There is probably no perfect way to do this as we don't want to sync too frequently and overload our database. Added an on-demand refresh triggered by admins looking at the data, it may help to add a note on the frontend saying that unverified users can be out of sync, and refreshing the page may help.

Changes

  • Increase sync frequency for all user data to every half-hour
  • Create a new function that just syncs unverified users (with a basic throttling mechanism to stop this happening too often)
  • Trigger refresh of unverified users whenever admins specifically look at verified/unverified users
  • Unit tests

Checklist

  • I have commented my code, particularly in hard-to-understand areas
  • I have added unit / integration tests that prove my fix is effective or that my feature works
  • I have run all tests locally and they pass
  • I have updated the documentation (if applicable)
  • For any new secrets, I have updated the shared spreadsheet and the GitHub Secrets.

How to Test Manually (if necessary)

Run uv run pytest

amandazhuyilan
amandazhuyilan previously approved these changes Dec 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants