diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2023-02-09 09:49:04 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-09 09:49:04 -0500 |
commit | 733531ee3e695da92f10e01b24f62ee35e09e4cd (patch) | |
tree | 07488950d1c65406f968ee38c0e384be255eeb57 /synapse/storage | |
parent | Proper types for `tests.module_api` (#15031) (diff) | |
download | synapse-733531ee3e695da92f10e01b24f62ee35e09e4cd.tar.xz |
Add final type hint to synapse.server. (#15035)
Diffstat (limited to 'synapse/storage')
-rw-r--r-- | synapse/storage/_base.py | 2 | ||||
-rw-r--r-- | synapse/storage/database.py | 1 | ||||
-rw-r--r-- | synapse/storage/databases/main/events.py | 2 |
3 files changed, 4 insertions, 1 deletions
diff --git a/synapse/storage/_base.py b/synapse/storage/_base.py index 41d9111019..481fec72fe 100644 --- a/synapse/storage/_base.py +++ b/synapse/storage/_base.py @@ -37,6 +37,8 @@ class SQLBaseStore(metaclass=ABCMeta): per data store (and not one per physical database). """ + db_pool: DatabasePool + def __init__( self, database: DatabasePool, diff --git a/synapse/storage/database.py b/synapse/storage/database.py index e20c5c5302..feaa6cdd07 100644 --- a/synapse/storage/database.py +++ b/synapse/storage/database.py @@ -499,6 +499,7 @@ class DatabasePool: """ _TXN_ID = 0 + engine: BaseDatabaseEngine def __init__( self, diff --git a/synapse/storage/databases/main/events.py b/synapse/storage/databases/main/events.py index 1536937b67..cb66376fb4 100644 --- a/synapse/storage/databases/main/events.py +++ b/synapse/storage/databases/main/events.py @@ -306,7 +306,7 @@ class PersistEventsStore: # The set of event_ids to return. This includes all soft-failed events # and their prev events. - existing_prevs = set() + existing_prevs: Set[str] = set() def _get_prevs_before_rejected_txn( txn: LoggingTransaction, batch: Collection[str] |