From c72df18795954a84473c3da46af9f54d6e8962ec Mon Sep 17 00:00:00 2001 From: Pletnev Stepan Vladimirovich Date: Tue, 30 Apr 2019 13:28:58 +0500 Subject: [PATCH 1/2] fixed return type annotation for WSMessage.json() --- CONTRIBUTORS.txt | 1 + aiohttp/http_websocket.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTORS.txt b/CONTRIBUTORS.txt index 07a9b81347f..c576886b93f 100644 --- a/CONTRIBUTORS.txt +++ b/CONTRIBUTORS.txt @@ -201,6 +201,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 From 5c50797d7a90ac1723187867997425d305fe3389 Mon Sep 17 00:00:00 2001 From: Pletnev Stepan Vladimirovich Date: Tue, 30 Apr 2019 13:40:59 +0500 Subject: [PATCH 2/2] add CHANGES/3720.bugfix --- CHANGES/3720.bugfix | 1 + 1 file changed, 1 insertion(+) 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()