Skip to content

Commit 646cb6f

Browse files
Add type annotation to visited_chains (#17125)
This should fix CI on `develop`. Broke in 0fe9e1f, presumably due to a `mypy` dependency upgrade.
1 parent 0fe9e1f commit 646cb6f

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

changelog.d/17125.misc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix type annotation for `visited_chains` after `mypy` upgrade.

synapse/storage/databases/main/events.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2454,7 +2454,7 @@ def exists_path_from(
24542454
return target_seq <= src_seq
24552455

24562456
# We have to graph traverse the links to check for indirect paths.
2457-
visited_chains = collections.Counter()
2457+
visited_chains: Dict[int, int] = collections.Counter()
24582458
search = [(src_chain, src_seq)]
24592459
while search:
24602460
chain, seq = search.pop()

0 commit comments

Comments
 (0)