Add type hints to synapse/storage/databases/main/e2e_room_keys.py (#11549)

This commit is contained in:
Sean Quah 2021-12-14 17:46:47 +00:00 committed by GitHub
parent 0147b3de20
commit ecfcd9bbbe
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 188 additions and 79 deletions

View file

@ -59,9 +59,11 @@ StateKey = Tuple[str, str]
StateMap = Mapping[StateKey, T]
MutableStateMap = MutableMapping[StateKey, T]
# the type of a JSON-serialisable dict. This could be made stronger, but it will
# do for now.
# JSON types. These could be made stronger, but will do for now.
# A JSON-serialisable dict.
JsonDict = Dict[str, Any]
# A JSON-serialisable object.
JsonSerializable = object
# Note that this seems to require inheriting *directly* from Interface in order