From 2995db11af58ac198f751cbf98bedc255a7d4686 Mon Sep 17 00:00:00 2001 From: "Olivier Wilkinson (reivilibre)" Date: Tue, 28 Feb 2023 10:35:49 +0000 Subject: [PATCH] Add comment about 1<<62 --- synapse/handlers/user_directory.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/synapse/handlers/user_directory.py b/synapse/handlers/user_directory.py index e16e57748ac6..28a92d41d6fc 100644 --- a/synapse/handlers/user_directory.py +++ b/synapse/handlers/user_directory.py @@ -608,6 +608,9 @@ async def _unsafe_refresh_remote_profiles(self) -> None: if not servers_to_refresh: # Do we have any backing-off servers that we should try again # for eventually? + # By setting `now` is a point in the far future, we can ask for + # which server/user is next to be refreshed, even though it is + # not actually refreshable *now*. end_of_time = 1 << 62 backing_off_servers = ( await self.store.get_remote_servers_with_profiles_to_refresh(