mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-07-27 02:25:24 -04:00
Remove redundant types from comments. (#14412)
Remove type hints from comments which have been added as Python type hints. This helps avoid drift between comments and reality, as well as removing redundant information. Also adds some missing type hints which were simple to fill in.
This commit is contained in:
parent
882277008c
commit
d8cc86eff4
55 changed files with 174 additions and 176 deletions
|
@ -1279,9 +1279,10 @@ class PersistEventsStore:
|
|||
Pick the earliest non-outlier if there is one, else the earliest one.
|
||||
|
||||
Args:
|
||||
events_and_contexts (list[(EventBase, EventContext)]):
|
||||
events_and_contexts:
|
||||
|
||||
Returns:
|
||||
list[(EventBase, EventContext)]: filtered list
|
||||
filtered list
|
||||
"""
|
||||
new_events_and_contexts: OrderedDict[
|
||||
str, Tuple[EventBase, EventContext]
|
||||
|
@ -1307,9 +1308,8 @@ class PersistEventsStore:
|
|||
"""Update min_depth for each room
|
||||
|
||||
Args:
|
||||
txn (twisted.enterprise.adbapi.Connection): db connection
|
||||
events_and_contexts (list[(EventBase, EventContext)]): events
|
||||
we are persisting
|
||||
txn: db connection
|
||||
events_and_contexts: events we are persisting
|
||||
"""
|
||||
depth_updates: Dict[str, int] = {}
|
||||
for event, context in events_and_contexts:
|
||||
|
@ -1580,13 +1580,11 @@ class PersistEventsStore:
|
|||
"""Update all the miscellaneous tables for new events
|
||||
|
||||
Args:
|
||||
txn (twisted.enterprise.adbapi.Connection): db connection
|
||||
events_and_contexts (list[(EventBase, EventContext)]): events
|
||||
we are persisting
|
||||
all_events_and_contexts (list[(EventBase, EventContext)]): all
|
||||
events that we were going to persist. This includes events
|
||||
we've already persisted, etc, that wouldn't appear in
|
||||
events_and_context.
|
||||
txn: db connection
|
||||
events_and_contexts: events we are persisting
|
||||
all_events_and_contexts: all events that we were going to persist.
|
||||
This includes events we've already persisted, etc, that wouldn't
|
||||
appear in events_and_context.
|
||||
inhibit_local_membership_updates: Stop the local_current_membership
|
||||
from being updated by these events. This should be set to True
|
||||
for backfilled events because backfilled events in the past do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue