From 8012f9a5b580972f8d0c3c6781bc73f12ab48d8a Mon Sep 17 00:00:00 2001 From: cibere <71997063+cibere@users.noreply.github.com> Date: Mon, 25 Nov 2024 14:42:22 -0800 Subject: [PATCH] add debug logging to the pusher socket --- kick/ws.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/kick/ws.py b/kick/ws.py index a1fbe11..346fe9c 100644 --- a/kick/ws.py +++ b/kick/ws.py @@ -4,13 +4,15 @@ from typing import TYPE_CHECKING from aiohttp import ClientWebSocketResponse as WebSocketResponse - +import logging from .livestream import PartialLivestream from .message import Message if TYPE_CHECKING: from .http import HTTPClient +LOG = logging.getLogger(__name__) + __all__ = () @@ -23,6 +25,7 @@ def __init__(self, ws: WebSocketResponse, *, http: HTTPClient): async def poll_event(self) -> None: raw_msg = await self.ws.receive() + LOG.debug(f"WS received: {raw_msg}") raw_data = raw_msg.json() data = json.loads(raw_data["data"])