mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-04 01:04:48 -04:00
Switch metaclass initialization to python 3-compatible syntax (#8326)
This commit is contained in:
parent
44dec6cbc4
commit
a3f124b821
8 changed files with 16 additions and 26 deletions
|
@ -259,14 +259,12 @@ def filter_to_clause(event_filter: Optional[Filter]) -> Tuple[str, List[str]]:
|
|||
return " AND ".join(clauses), args
|
||||
|
||||
|
||||
class StreamWorkerStore(EventsWorkerStore, SQLBaseStore):
|
||||
class StreamWorkerStore(EventsWorkerStore, SQLBaseStore, metaclass=abc.ABCMeta):
|
||||
"""This is an abstract base class where subclasses must implement
|
||||
`get_room_max_stream_ordering` and `get_room_min_stream_ordering`
|
||||
which can be called in the initializer.
|
||||
"""
|
||||
|
||||
__metaclass__ = abc.ABCMeta
|
||||
|
||||
def __init__(self, database: DatabasePool, db_conn, hs: "HomeServer"):
|
||||
super(StreamWorkerStore, self).__init__(database, db_conn, hs)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue