Log exceptions when failing to auto-join new user according to the `auto_join_rooms` option. (#17176)

Would have been useful for tracking down #16878.

Signed-off-by: Olivier 'reivilibre <oliverw@matrix.org>
This commit is contained in:
reivilibre 2024-05-22 14:22:33 +01:00 committed by GitHub
parent 7ef00b7628
commit 7e2412265d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

1
changelog.d/17176.misc Normal file
View File

@ -0,0 +1 @@
Log exceptions when failing to auto-join new user according to the `auto_join_rooms` option.

View File

@ -590,7 +590,7 @@ class RegistrationHandler:
# moving away from bare excepts is a good thing to do. # moving away from bare excepts is a good thing to do.
logger.error("Failed to join new user to %r: %r", r, e) logger.error("Failed to join new user to %r: %r", r, e)
except Exception as e: except Exception as e:
logger.error("Failed to join new user to %r: %r", r, e) logger.error("Failed to join new user to %r: %r", r, e, exc_info=True)
async def _auto_join_rooms(self, user_id: str) -> None: async def _auto_join_rooms(self, user_id: str) -> None:
"""Automatically joins users to auto join rooms - creating the room in the first place """Automatically joins users to auto join rooms - creating the room in the first place