Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Fix a type annotation in test_account_data.py and remove it from th…
Browse files Browse the repository at this point in the history
…e Mypy exclusion list. (#11657)

Co-authored-by: Patrick Cloke <clokep@users.noreply.github.com>
  • Loading branch information
reivilibre and clokep authored Dec 29, 2021
1 parent f82d38e commit 2c7f5e7
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions changelog.d/11657.misc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add missing type hints to storage classes.
1 change: 0 additions & 1 deletion mypy.ini
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ exclude = (?x)
|tests/server.py
|tests/server_notices/test_resource_limits_server_notices.py
|tests/state/test_v2.py
|tests/storage/test_account_data.py
|tests/storage/test_background_update.py
|tests/storage/test_base.py
|tests/storage/test_client_ips.py
Expand Down
4 changes: 2 additions & 2 deletions tests/storage/test_account_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

from typing import Iterable, Set
from typing import Iterable, Optional, Set

from synapse.api.constants import AccountDataTypes

Expand All @@ -25,7 +25,7 @@ def prepare(self, hs, reactor, clock):
self.user = "@user:test"

def _update_ignore_list(
self, *ignored_user_ids: Iterable[str], ignorer_user_id: str = None
self, *ignored_user_ids: Iterable[str], ignorer_user_id: Optional[str] = None
) -> None:
"""Update the account data to block the given users."""
if ignorer_user_id is None:
Expand Down

0 comments on commit 2c7f5e7

Please sign in to comment.