cyr-ius / hass-livebox-component

Livebox Component for Home assistant
MIT License
64 stars 21 forks source link

UnicodeDecodeError When Fetching Data #122

Closed MateoGreil closed 1 month ago

MateoGreil commented 4 months ago

Description

After completing the configuration of the Orange Livebox integration, I receive a "configuration completed successfully" message. image However, during the data loading process, an error occurs. I have tried both with and without SSL and on ports 80 and 443, but the issue persists. image

Error Details

Enregistreur: custom_components.livebox.coordinator
Source: helpers/update_coordinator.py:312
Integration: Orange Livebox (documentation, issues)
Occurred for the first time: 2 July 2024 at 20:18:46 (901 occurrences)
Last recorded: 16:43:42

Unexpected error fetching livebox data
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 312, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/livebox/coordinator.py", line 55, in _async_update_data
    devices, device_counters = await self.async_get_devices(lan_tracking)
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/livebox/coordinator.py", line 94, in async_get_devices
    devices = await self._make_request(
              ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/livebox/coordinator.py", line 181, in _make_request
    return await func(*args)
           ^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiosysbus/api/device.py", line 164, in async_get_devices
    return await self._auth.post("Devices", "get", conf)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiosysbus/auth.py", line 136, in post
    return await self.async_request(method="post", json=data)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiosysbus/auth.py", line 117, in async_request
    rjson = await response.json()
            ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/aiohttp_client.py", line 79, in json
    return await super().json(*args, loads=loads, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/client_reqrep.py", line 1192, in json
    return loads(stripped.decode(encoding))
                 ^^^^^^^^^^^^^^^^^^^^^^^^^
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xfd in position 151354: invalid start byte

Environment

hass-livebox-component version: 2.2.7

Home Assistant version:

Livebox Firmware Version:

github-actions[bot] commented 1 month ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.