Skip to content

Commit

Permalink
chore: update dependencies, fix websockets client
Browse files Browse the repository at this point in the history
  • Loading branch information
thepiwo committed Dec 3, 2024
1 parent 500d40f commit 58bcb2d
Show file tree
Hide file tree
Showing 3 changed files with 1,009 additions and 741 deletions.
6 changes: 3 additions & 3 deletions iolite_client/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ async def _fetch_heating(self):
logger.info("Connecting to heating WS")
uri = f"{self.BASE_URL}/heating/ws?SID={self.sid}"
async with websockets.connect(
uri, extra_headers=self._get_default_headers()
uri, additional_headers=self._get_default_headers()
) as websocket:
async for response in websocket:
logger.debug(
Expand All @@ -183,7 +183,7 @@ async def _devices_handler(self):
logger.info("Connecting to devices WS")
uri = f"{self.BASE_URL}/devices/ws?SID={self.sid}"
async with websockets.connect(
uri, extra_headers=self._get_default_headers()
uri, additional_headers=self._get_default_headers()
) as websocket:
async for response in websocket:
logger.debug(
Expand All @@ -199,7 +199,7 @@ async def _fetch_application(self, requests: list):
logger.info("Connecting to JSON WS")
uri = f"{self.BASE_URL}/bus/websocket/application/json?SID={self.sid}"
async with websockets.connect(
uri, extra_headers=self._get_default_headers()
uri, additional_headers=self._get_default_headers()
) as websocket:
for request in requests:
await self.__send_request(request, websocket)
Expand Down
Loading

0 comments on commit 58bcb2d

Please sign in to comment.