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

Commit

Permalink
Pull in updated canonicaljson lib
Browse files Browse the repository at this point in the history
so the protocol check just works
  • Loading branch information
David Robertson committed Feb 15, 2023
1 parent d695914 commit edab83f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
6 changes: 3 additions & 3 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions synapse/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,7 @@
try:
from canonicaljson import set_json_library

# type-ignore: I think there has been a regression in mypy 1.0.0 in how it checks
# modules against Protocols.
set_json_library(json) # type: ignore[arg-type]
set_json_library(json)
except ImportError:
pass

Expand Down
2 changes: 1 addition & 1 deletion synapse/storage/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
from types import TracebackType
from typing import (
Any,
Callable,
Iterator,
List,
Mapping,
Expand All @@ -22,7 +23,6 @@
Tuple,
Type,
Union,
Callable,
)

from typing_extensions import Protocol
Expand Down

0 comments on commit edab83f

Please sign in to comment.