summary refs log tree commit diff
path: root/synapse/handlers/auth.py
diff options
context:
space:
mode:
authorAndrew Morgan <andrew@amorgan.xyz>2020-12-31 14:35:45 +0000
committerAndrew Morgan <andrew@amorgan.xyz>2020-12-31 14:35:45 +0000
commit883c742960874946a1bbddc38b7ae9a7e3e25a8b (patch)
tree71b0e3347dcc8f79a079b679d8126e6498c69bf8 /synapse/handlers/auth.py
parentMerge commit 'c3119d153' into anoa/dinsic_release_1_23_1 (diff)
parentCheck support room has only two users before sending a notice (#8728) (diff)
downloadsynapse-883c742960874946a1bbddc38b7ae9a7e3e25a8b.tar.xz
Merge commit '89700dfb8' into anoa/dinsic_release_1_23_1
Diffstat (limited to 'synapse/handlers/auth.py')
-rw-r--r--synapse/handlers/auth.py13
1 files changed, 9 insertions, 4 deletions
diff --git a/synapse/handlers/auth.py b/synapse/handlers/auth.py

index ff103cbb92..213baea2e3 100644 --- a/synapse/handlers/auth.py +++ b/synapse/handlers/auth.py
@@ -181,10 +181,15 @@ class AuthHandler(BaseHandler): # better way to break the loop account_handler = ModuleApi(hs, self) - self.password_providers = [ - module(config=config, account_handler=account_handler) - for module, config in hs.config.password_providers - ] + self.password_providers = [] + for module, config in hs.config.password_providers: + try: + self.password_providers.append( + module(config=config, account_handler=account_handler) + ) + except Exception as e: + logger.error("Error while initializing %r: %s", module, e) + raise logger.info("Extra password_providers: %r", self.password_providers)