From: kriskros341 Date: Wed, 27 Jan 2021 15:37:05 +0000 (+0100) Subject: Uppercase A in Any X-Git-Tag: v6.2.0b1~53^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1cd099b67de4dc81e121729a7561dd04134d0aee;p=thirdparty%2Ftornado.git Uppercase A in Any --- diff --git a/tornado/websocket.py b/tornado/websocket.py index 256a5ee7f..3a83707ab 100644 --- a/tornado/websocket.py +++ b/tornado/websocket.py @@ -680,7 +680,7 @@ class WebSocketProtocol(abc.ABC): @abc.abstractmethod def write_message( - self, message: Union[str, bytes], binary: bool = False + self, message: Union[str, bytes, Dict[str, Any]], binary: bool = False ) -> "Future[None]": raise NotImplementedError() @@ -1072,7 +1072,7 @@ class WebSocketProtocol13(WebSocketProtocol): return self.stream.write(frame) def write_message( - self, message: Union[str, bytes, Dict[str, any]], binary: bool = False + self, message: Union[str, bytes, Dict[str, Any]], binary: bool = False ) -> "Future[None]": """Sends the given message to the client of this Web Socket.""" if binary: @@ -1495,7 +1495,7 @@ class WebSocketClientConnection(simple_httpclient._HTTPConnection): future_set_result_unless_cancelled(self.connect_future, self) def write_message( - self, message: Union[str, bytes, Dict[str, any]], binary: bool = False + self, message: Union[str, bytes, Dict[str, Any]], binary: bool = False ) -> "Future[None]": """Sends a message to the WebSocket server.