Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit e3ccb15

Browse files
author
David Robertson
committed
Complain at startup if we can't find fed senders
1 parent 164e0fb commit e3ccb15

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

synapse/crypto/keyring.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
RequestSendFailed,
4242
SynapseError,
4343
)
44+
from synapse.config import ConfigError
4445
from synapse.config.key import TrustedKeyServer
4546
from synapse.crypto.types import _FetchKeyRequest
4647
from synapse.events import EventBase
@@ -927,6 +928,8 @@ class InternalWorkerRequestKeyFetcher(KeyFetcher):
927928
def __init__(self, hs: "HomeServer"):
928929
super().__init__(hs)
929930
self._federation_shard_config = hs.config.worker.federation_shard_config
931+
if not self._federation_shard_config.instances:
932+
raise ConfigError("No federation senders configured")
930933
self._client = ReplicationFetchKeysEndpoint.make_client(hs)
931934

932935
async def _fetch_keys(

0 commit comments

Comments
 (0)