Use type hinting generics in standard collections (#19046)

aka PEP 585, added in Python 3.9

 - https://peps.python.org/pep-0585/
 - https://docs.astral.sh/ruff/rules/non-pep585-annotation/
This commit is contained in:
Andrew Ferrazzutti authored and GitHub committed 2025-10-22 16:48:19 -05:00
1 parent cba3a814c6
commit fc244bb592
539 files changed
+4599 -5066

No files matched your search

+1 -2
View File
@@ -18,7 +18,6 @@
# [This file includes modifications made by New Vector Limited]
#
#
from typing import List
from unittest import mock
from twisted.internet.testing import MemoryReactor
@@ -34,7 +33,7 @@ from synapse.util.clock import Clock
from tests.unittest import HomeserverTestCase
def fake_listdir(filepath: str) -> List[str]:
def fake_listdir(filepath: str) -> list[str]:
"""
A fake implementation of os.listdir which we can use to mock out the filesystem.