diff options
author | Sean Quah <8349537+squahtx@users.noreply.github.com> | 2021-12-13 17:05:00 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-13 17:05:00 +0000 |
commit | 5305a5e88144828419249fd9e4c5198d92276a44 (patch) | |
tree | 6c03eceaef4ae259d52510d64d1b9e90018483d1 /synapse/storage/databases/main/events.py | |
parent | Add type hints to `synapse/storage/databases/main/end_to_end_keys.py` (#11551) (diff) | |
download | synapse-5305a5e88144828419249fd9e4c5198d92276a44.tar.xz |
Type hint the constructors of the data store classes (#11555)
Diffstat (limited to 'synapse/storage/databases/main/events.py')
-rw-r--r-- | synapse/storage/databases/main/events.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/synapse/storage/databases/main/events.py b/synapse/storage/databases/main/events.py index 5184e6bf85..81e67ece55 100644 --- a/synapse/storage/databases/main/events.py +++ b/synapse/storage/databases/main/events.py @@ -41,10 +41,13 @@ from synapse.events import EventBase # noqa: F401 from synapse.events.snapshot import EventContext # noqa: F401 from synapse.logging.utils import log_function from synapse.storage._base import db_to_json, make_in_list_sql_clause -from synapse.storage.database import DatabasePool, LoggingTransaction +from synapse.storage.database import ( + DatabasePool, + LoggingDatabaseConnection, + LoggingTransaction, +) from synapse.storage.databases.main.events_worker import EventCacheEntry from synapse.storage.databases.main.search import SearchEntry -from synapse.storage.types import Connection from synapse.storage.util.id_generators import AbstractStreamIdGenerator from synapse.storage.util.sequence import SequenceGenerator from synapse.types import StateMap, get_domain_from_id @@ -95,7 +98,7 @@ class PersistEventsStore: hs: "HomeServer", db: DatabasePool, main_data_store: "DataStore", - db_conn: Connection, + db_conn: LoggingDatabaseConnection, ): self.hs = hs self.db_pool = db |