Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
tornado: Set an explicit SUPPORTED_METHODS.
Alex Vandiver875622fe578d
diff --git a/zerver/tornado/handlers.py b/zerver/tornado/handlers.pyindex a285ac1b22a..c5881a6d722 100644--- a/zerver/tornado/handlers.py+++ b/zerver/tornado/handlers.py@@ -1,6 +1,6 @@import loggingfrom contextlib import suppress-from typing import Any, Dict, List, Optional+from typing import Any, Collection, Dict, List, Optionalfrom urllib.parse import unquoteimport tornado.web@@ -83,6 +83,8 @@ def finish_handler(handler_id: int, event_queue_id: str, contents: List[Dict[strclass AsyncDjangoHandler(tornado.web.RequestHandler):handler_id: int+ SUPPORTED_METHODS: Collection[str] = {"GET", "HEAD", "POST", "DELETE"} # type: ignore[assignment] # https://github.com/tornadoweb/tornado/pull/3354+@overridedef initialize(self, django_handler: base.BaseHandler) -> None:self.django_handler = django_handler