summary refs log tree commit diff
path: root/synapse/server.py
diff options
context:
space:
mode:
authordependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>2024-07-05 12:35:57 +0000
committerGitHub <noreply@github.com>2024-07-05 12:35:57 +0000
commit20de685a4b500212d19acda5f637d51a8dd6be4e (patch)
treecb4ede58d67fc349a4c783b99eb178bd28e061cb /synapse/server.py
parentAllow enabling sliding sync per-user (#17393) (diff)
downloadsynapse-20de685a4b500212d19acda5f637d51a8dd6be4e.tar.xz
Bump ruff from 0.3.7 to 0.5.0 (#17381)
Diffstat (limited to '')
-rw-r--r--synapse/server.py14
1 files changed, 9 insertions, 5 deletions
diff --git a/synapse/server.py b/synapse/server.py

index ae927c3904..4a3f9ff934 100644 --- a/synapse/server.py +++ b/synapse/server.py
@@ -28,7 +28,7 @@ import abc import functools import logging -from typing import TYPE_CHECKING, Callable, Dict, List, Optional, TypeVar, cast +from typing import TYPE_CHECKING, Callable, Dict, List, Optional, Type, TypeVar, cast from typing_extensions import TypeAlias @@ -161,6 +161,7 @@ if TYPE_CHECKING: from synapse.handlers.jwt import JwtHandler from synapse.handlers.oidc import OidcHandler from synapse.handlers.saml import SamlHandler + from synapse.storage._base import SQLBaseStore # The annotation for `cache_in_self` used to be @@ -255,10 +256,13 @@ class HomeServer(metaclass=abc.ABCMeta): "stats", ] - # This is overridden in derived application classes - # (such as synapse.app.homeserver.SynapseHomeServer) and gives the class to be - # instantiated during setup() for future return by get_datastores() - DATASTORE_CLASS = abc.abstractproperty() + @property + @abc.abstractmethod + def DATASTORE_CLASS(self) -> Type["SQLBaseStore"]: + # This is overridden in derived application classes + # (such as synapse.app.homeserver.SynapseHomeServer) and gives the class to be + # instantiated during setup() for future return by get_datastores() + pass def __init__( self,