Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

roborock S8 Pro Ultra goes unavailable and never comes back #125169

Open
stuartp44 opened this issue Sep 3, 2024 · 20 comments
Open

roborock S8 Pro Ultra goes unavailable and never comes back #125169

stuartp44 opened this issue Sep 3, 2024 · 20 comments

Comments

@stuartp44
Copy link

stuartp44 commented Sep 3, 2024

The problem

I have noted that one of my two roborock S8 Pro Ultra's will become unavailable after non pre-determind time and never come back online unless I restart the plugin. Once done, the integration will come back online for another none pre-determind time and go unavailable again.

While looking through the logs, I can see a clean connection to the offending unit aka "[Upstairs] Connected to 192.168.13.144" and then I see (See below) which concedes with the error I am seeing in the UI
image
image

So with this being said, I can simply restart the plugin and everything is good again with no problems until the next time it goes unavailable. Of course I can simply setup an automation to restart the plugin every time the device goes unavailable but that is not a "fix" in my eyes and it gets quite dangerous if there is a genuine reason for the outage.

The strange bit is the fact when I restart there is nothing wrong and the unit comes nicely back online with no issues (telling me its some sort of drop out failure with no retry). If there was a actual "issue" the unit should not come back after a restart of the integration.

image

I am taking a guess this could be caused by my environment, which is due to the Unifi system I have and the multiple access points I have within it. I have noted that the unit roams between two access points a lot and to try and stop this (maybe this being the issue), I have locked the unit to one access point (Again, not ideal but a shot at getting this working with better stability). Again, I don't think this should matter as the unit, after the roam, is ready for connection again but the integration will never try again? (once again, the only way to get this working again is to restart the plugin).

What version of Home Assistant Core has the issue?

core-2024.8.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

roborock

Link to integration documentation on our website

No response

Diagnostics information

config_entry-unifi-352d2a4719893742bde383cdf371cab7.json
home-assistant_roborock_2024-09-03T17-20-59.047Z.log

Example YAML snippet

No response

Anything in the logs that might be useful for us?

[homeassistant.components.websocket_api.http.connection] [139698419415024] 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 2763, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2806, 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 "/usr/src/homeassistant/homeassistant/components/roborock/switch.py", line 152, in async_turn_off
    await self.entity_description.update_value(
  File "/usr/local/lib/python3.12/site-packages/roborock/version_1_apis/roborock_client_v1.py", line 126, in close_value
    response = await self.api._send_command(self.attribute.close_command, params)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/roborock/version_1_apis/roborock_local_client_v1.py", line 35, in _send_command
    return await self.send_message(roborock_message)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/roborock/version_1_apis/roborock_local_client_v1.py", line 57, in send_message
    (response, err) = await async_response
                      ^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/roborock/api.py", line 108, in _wait_response
    raise RoborockTimeout(f"id={request_id} Timeout after {self.queue_timeout} seconds") from None
roborock.exceptions.RoborockTimeout: id=133317 Timeout after 4 seconds

Additional information

No response

@stuartp44 stuartp44 changed the title Roborock goes unavailable and never comes back after a unexpected exception Roborock goes unavailable and never comes back Sep 3, 2024
@stuartp44 stuartp44 changed the title Roborock goes unavailable and never comes back roborock S8 Pro Ultra goes unavailable and never comes back Sep 3, 2024
@home-assistant
Copy link

home-assistant bot commented Sep 4, 2024

Hey there @Lash-L, mind taking a look at this issue as it has been labeled with an integration (roborock) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of roborock can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign roborock Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


roborock documentation
roborock source
(message by IssueLinks)

@richie510
Copy link

I’m getting this same problem periodically on my Roborock Q5 Max+. Curiously, I’m not seeing this problem on my Roborock S4. The Q5 Max+ is somewhat new for me, so I do not know for sure if it started with the new device in July, or started happening more in August with the August release.

@FaBay89
Copy link

FaBay89 commented Oct 6, 2024

Same here with qrevo pro. After restart of the integration it comes back and work normal for some time

edit: I have a fritzbox, no ubiquity

@ethemcemozkan
Copy link
Contributor

Same here, I have s8 maxv pro. Like others reload of the integration fixes it until it happens again

@Cyrelion
Copy link

Same here, S8 Pro Ultra

@jimaek
Copy link

jimaek commented Oct 10, 2024

Same problem, S8 Pro Ultra

1 similar comment
@maxxnet2
Copy link

Same problem, S8 Pro Ultra

@pegoto
Copy link

pegoto commented Oct 11, 2024

Same with the two S7 Max Ultras I have, and they don't always become unavailable at the same time, I too have a Ubiquity network.

@Ojoachim71
Copy link

Ojoachim71 commented Oct 13, 2024

Same here. S7.

Edit: Fritzbox 7590

@schmidt-daniel
Copy link

Well... same here. Qrevo Curv, Fritzbox 7590.
No issues when using the Roborock app.

@IngmarStein
Copy link

Same problem with an S8. Until this is fixed, I've set up an automation to reload the integration if the robot is unavailable for a minute:

alias: Reload Roborock S8 if unavailable
description: ""
triggers:
  - trigger: state
    entity_id:
      - vacuum.roborock_s8_eg
    to: unavailable
    for:
      hours: 0
      minutes: 1
      seconds: 0
conditions: []
actions:
  - action: homeassistant.reload_config_entry
    metadata: {}
    data: {}
    target:
      device_id: xxx
mode: single

@pegoto
Copy link

pegoto commented Oct 20, 2024

Same problem with an S8. Until this is fixed, I've set up an automation to reload the integration if the robot is unavailable for a minute:

alias: Reload Roborock S8 if unavailable
description: ""
triggers:
  - trigger: state
    entity_id:
      - vacuum.roborock_s8_eg
    to: unavailable
    for:
      hours: 0
      minutes: 1
      seconds: 0
conditions: []
actions:
  - action: homeassistant.reload_config_entry
    metadata: {}
    data: {}
    target:
      device_id: xxx
mode: single

Thanks for this! I was looking on how to restart the integration, but couldn't see it, so I am rebooting HA every time it happens, which is sometimes once a day or three times a day. I have it send me a push message before rebooting so I can see how often it happens.

@JIOB
Copy link

JIOB commented Oct 25, 2024

Same here with S7 Max Ultra and Qrevo S thanks for the tip on the workaround @IngmarStein

@Lash-L
Copy link
Contributor

Lash-L commented Nov 8, 2024

Hi all - Sorry for the delay and for being so patient. I have very little time to work on projects like this right now - and it's just me for this integration. With how fast Roborock puts out new vacuums that break old functionality, it can often be very overwhelming.

That being said, this issue would be fixed with a long term goal of mine which is to add retries and a bit better error handling, but that's a tall order.

So looking at your logs - your vacuum is specifically timing out when you are trying to turn off a switch. Do you have an automation running for Roborock? If so can you please share it?

@Wolfir77
Copy link

My roborock q7 goes offline the same way, i have a very simple automation with pushbutton to start and stop.

alias: Cleanrobot
description: ""
triggers:
  - device_id: 318b411fbd4d520a3b50d6e986e6d9e1
    domain: zha
    type: remote_button_short_press
    subtype: button
    trigger: device
    id: "1"
  - device_id: 318b411fbd4d520a3b50d6e986e6d9e1
    domain: zha
    type: remote_button_long_press
    subtype: button
    trigger: device
    id: "2"
conditions: []
actions:
  - alias: Return to dock
    if:
      - condition: trigger
        id:
          - "2"
    then:
      - action: vacuum.return_to_base
        metadata: {}
        data: {}
        target:
          entity_id: vacuum.roborock_q7_max
  - if:
      - condition: trigger
        id:
          - "1"
      - condition: device
        device_id: 36ee4ebdca45400704f3b134da6d5cf2
        domain: vacuum
        entity_id: c74d7e49cc1ad0dd3091b044ea478877
        type: is_cleaning
    then:
      - action: vacuum.pause
        metadata: {}
        data: {}
        target:
          entity_id: vacuum.roborock_q7_max
    alias: Pause
  - alias: Start
    if:
      - condition: trigger
        id:
          - "1"
      - type: is_not_running
        condition: device
        device_id: 36ee4ebdca45400704f3b134da6d5cf2
        entity_id: dc7c39c52df2b6687accd96fb44d45a6
        domain: binary_sensor
    then:
      - action: vacuum.start
        metadata: {}
        data: {}
        target:
          entity_id: vacuum.roborock_q7_max
mode: single

@michaelsleen
Copy link

michaelsleen commented Dec 18, 2024

I am experiencing the same issue with S8 MaxV Ultra on 2024.12.4. Not entirely sure when the connection broke, but I'm pretty sure I first set it up via the core integration (not HACS) after the 2024.12 release. Have only used it on the core integration, never with HACS, and I don't have any Govee devices. Deleting the integration and re-adding does not solve the issue. Below are the logs:

Logger: roborock.containers
Source: /usr/local/lib/python3.13/site-packages/roborock/containers.py:128
First occurred: 4:23:07 PM (4 occurrences)
Last logged: 4:26:43 PM

HomeDataDevice.__init__() got an unexpected keyword argument 'cid'
Traceback (most recent call last):
  File "/usr/local/lib/python3.13/site-packages/roborock/containers.py", line 112, in convert_to_class_obj
    return_list.append(cls_type.from_dict(obj))
                       ~~~~~~~~~~~~~~~~~~^^^^^
  File "/usr/local/lib/python3.13/site-packages/roborock/containers.py", line 166, in from_dict
    return cls(**data)
TypeError: HomeDataDevice.__init__() got an unexpected keyword argument 'cid'
Logger: homeassistant.config_entries
Source: config_entries.py:640
First occurred: 4:23:07 PM (4 occurrences)
Last logged: 4:26:43 PM

Error setting up entry MYEMAIL@gmail.com for roborock
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 640, in __async_setup_with_context
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/roborock/__init__.py", line 72, in async_setup_entry
    device.duid: device for device in all_devices
    ^^^^^^^^^^^
AttributeError: 'dict' object has no attribute 'duid'

@Lash-L
Copy link
Contributor

Lash-L commented Dec 18, 2024

I am experiencing the same issue with S8 MaxV Ultra on 2024.12.4. Not entirely sure when the connection broke, but I'm pretty sure I first set it up via the core integration (not HACS) after the 2024.12 release. Have only used it on the core integration, never with HACS, and I don't have any Govee devices. Deleting the integration and re-adding does not solve the issue. Below are the logs:

Logger: roborock.containers
Source: /usr/local/lib/python3.13/site-packages/roborock/containers.py:128
First occurred: 4:23:07 PM (4 occurrences)
Last logged: 4:26:43 PM

HomeDataDevice.__init__() got an unexpected keyword argument 'cid'
Traceback (most recent call last):
  File "/usr/local/lib/python3.13/site-packages/roborock/containers.py", line 112, in convert_to_class_obj
    return_list.append(cls_type.from_dict(obj))
                       ~~~~~~~~~~~~~~~~~~^^^^^
  File "/usr/local/lib/python3.13/site-packages/roborock/containers.py", line 166, in from_dict
    return cls(**data)
TypeError: HomeDataDevice.__init__() got an unexpected keyword argument 'cid'
Logger: homeassistant.config_entries
Source: config_entries.py:640
First occurred: 4:23:07 PM (4 occurrences)
Last logged: 4:26:43 PM

Error setting up entry MYEMAIL@gmail.com for roborock
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 640, in __async_setup_with_context
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/roborock/__init__.py", line 72, in async_setup_entry
    device.duid: device for device in all_devices
    ^^^^^^^^^^^
AttributeError: 'dict' object has no attribute 'duid'

Please see #133533 - you have a different issue than what was posted and it has been resolved - just waiting for the new HA version

@michaelsleen
Copy link

Confirming this appears to be fixed with 2204.12.5, thanks!

@Wolfir77
Copy link

All works now thanks great job. 👍

@srescio
Copy link
Contributor

srescio commented Dec 29, 2024

same, upgraded to 2204.12.5, fixed 👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests