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 e4b86241333..e04e846f397 100644 --- a/CONTRIBUTORS.txt +++ b/CONTRIBUTORS.txt @@ -200,6 +200,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