From ad2c1872a0548c84ef812b2cc03434d3b8b56d05 Mon Sep 17 00:00:00 2001 From: fa1l Date: Mon, 6 May 2019 23:03:44 +0500 Subject: [PATCH] fixed return type annotation for WSMessage.json() (#3720) --- CHANGES/3720.bugfix | 1 + CONTRIBUTORS.txt | 1 + aiohttp/http_websocket.py | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 CHANGES/3720.bugfix diff --git a/CHANGES/3720.bugfix b/CHANGES/3720.bugfix new file mode 100644 index 00000000000..f02318f417e --- /dev/null +++ b/CHANGES/3720.bugfix @@ -0,0 +1 @@ +Fixed return type annotation for WSMessage.json() diff --git a/CONTRIBUTORS.txt b/CONTRIBUTORS.txt index b775479cab1..260c579d718 100644 --- a/CONTRIBUTORS.txt +++ b/CONTRIBUTORS.txt @@ -202,6 +202,7 @@ Simon Kennedy Sin-Woo Bang Stanislas Plum Stanislav Prokop +Stepan Pletnev Stephen Granade Steven Seguin Sunghyun Hwang diff --git a/aiohttp/http_websocket.py b/aiohttp/http_websocket.py index d8fc10f4567..f27c547f49d 100644 --- a/aiohttp/http_websocket.py +++ b/aiohttp/http_websocket.py @@ -83,7 +83,7 @@ class WSMsgType(IntEnum): class WSMessage(_WSMessageBase): def json(self, *, # type: ignore - loads: Callable[[Any], Any]=json.loads) -> None: + loads: Callable[[Any], Any]=json.loads) -> Any: """Return parsed JSON data. .. versionadded:: 0.22