galletn / iaqualink

Home Assistant Iaqualink Vacuums Robots
7 stars 1 forks source link

Crash at init and at Vacuum.start service call: #25

Open tmenguy opened 1 week ago

tmenguy commented 1 week ago

Hi,

Just adding in case you never seen it

On latest HA, latest iAqualink :

Logger: homeassistant.components.websocket_api.http.connection Source: components/websocket_api/commands.py:241 integration: Home Assistant WebSocket API (documentation, issues) First occurred: July 4, 2024 at 11:59:12 PM (2 occurrences) Last logged: July 4, 2024 at 11:59:55 PM

[281472418726384] Unexpected exception Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 241, in handle_call_service response = await hass.services.async_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2731, in async_call response_data = await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2774, in _execute_service return await target(service_call) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 999, in entity_service_call single_response = await _handle_entity_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1071, in _handle_entity_call result = await task ^^^^^^^^^^ File "/config/custom_components/iaqualinkRobots/vacuum.py", line 186, in async_start data = await self.setCleanerState(request) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/iaqualinkRobots/vacuum.py", line 393, in setCleanerState return message.json() ^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/aiohttp/http_websocket.py", line 121, in json return loads(self.data) ^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/json/init.py", line 339, in loads raise TypeError(f'the JSON object must be str, bytes or bytearray, ' TypeError: the JSON object must be str, bytes or bytearray, not int

Error executing service: <ServiceCall vacuum.start (c:01J1ZVG67CYWGD2YNJ2N6RK6KY): entity_id=['vacuum.peyrebelle_pool_robot']> Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/core.py", line 2751, in _run_service_call_catch_exceptions await coro_or_task File "/usr/src/homeassistant/homeassistant/core.py", line 2774, in _execute_service return await target(service_call) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 999, in entity_service_call single_response = await _handle_entity_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1071, in _handle_entity_call result = await task ^^^^^^^^^^ File "/config/custom_components/iaqualinkRobots/vacuum.py", line 186, in async_start data = await self.setCleanerState(request) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/iaqualinkRobots/vacuum.py", line 393, in setCleanerState return message.json() ^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/aiohttp/http_websocket.py", line 121, in json return loads(self.data) ^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/json/init.py", line 339, in loads raise TypeError(f'the JSON object must be str, bytes or bytearray, ' TypeError: the JSON object must be str, bytes or bytearray, not int

tmenguy commented 1 week ago

Robot : RA 6900 iQ Well connected and accessible

galletn commented 1 week ago

are you running the latest version of the code?

galletn commented 1 week ago

or did you try to run the cleaning before it got populated? did not try to break it yet myself 🤕

tmenguy commented 1 week ago

Hi, yes latest code. I exposed the vacuum to homekit through the HA HomeKit integration, maybe it was from here

tmenguy commented 1 week ago

I'll see when I can reproduce those it I see a pattern ....