1
0

Ignore monkey-patching functions. mypy doesn't currently allow this.

See https://github.com/python/mypy/issues/2427 for details/complaints.
This commit is contained in:
Andrew Morgan
2021-11-16 00:11:36 +00:00
parent 83be0d7e86
commit 2c7e732233

View File

@@ -341,12 +341,12 @@ def setup_test_homeserver(
async def hash(p):
return hashlib.md5(p.encode("utf8")).hexdigest()
hs.get_auth_handler().hash = hash
hs.get_auth_handler().hash = hash # type: ignore
async def validate_hash(p, h):
return hashlib.md5(p.encode("utf8")).hexdigest() == h
hs.get_auth_handler().validate_hash = validate_hash
hs.get_auth_handler().validate_hash = validate_hash # type: ignore
return hs