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

Vaccum Roboter S7 from roborock are not detected as an new entity #49022

Closed
ferropolis opened this issue Apr 10, 2021 · 12 comments · Fixed by #50129
Closed

Vaccum Roboter S7 from roborock are not detected as an new entity #49022

ferropolis opened this issue Apr 10, 2021 · 12 comments · Fixed by #50129
Assignees
Labels
integration: xiaomi_miio waiting-for-upstream We're waiting for a change upstream

Comments

@ferropolis
Copy link

ferropolis commented Apr 10, 2021

The problem

Hello,

I have try to add the new S7 on two ways - but no one has bringing this phase to successful completion.

  1. I have add the integration of Xiaomi (Xiaomi Miio) and type in the IP and token from vaccum which was read out with token_extractor. The token is 32 digits in length and the IP of S7 in same range of my router and home assistant (all in 192.168.2.X).

  2. I have add the following code into configuration.yaml (see Example YAML snippet).

On both way the same result: S7 doesn't add as an seperate entity.
My presumption is, that the S7 is too new and have to add into "somewhere" (Sorry, I am not an expert on this).

What is version of Home Assistant Core has the issue?

core-2021.4.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

xiaomi_miio

Link to integration documentation on our website

https://www.home-assistant.io/integrations/xiaomi_miio/#xiaomi-mi-robot-vacuum

Example YAML snippet

vacuum:
  - platform: xiaomi_miio
    host: 192.168.2.8
    token: !secret xiaomi_token
    name: Helene_Wischer

Anything in the logs that might be useful for us?

No response

@rytilahti
Copy link
Member

Without more information (logs) it is hard to say where the problem is, the xiaomi miio vacuum integration should support all rockrobo vacuums though. The backend lib has recently got a couple of PRs specifically related to S7 support (the protocol got changed for cleaning history), so at some point S7 should work just out-of-the-box: rytilahti/python-miio#990 rytilahti/python-miio#1006

@AlfaJackal
Copy link

Same problem here! Roborock won't show up as an entity, only the name on the integrations page. Here is the log:

Logger: homeassistant.components.vacuum
Source: components/xiaomi_miio/vacuum.py:499 
Integration: Vacuum (documentation, issues) 
First occurred: 11:28:01 PM (1 occurrences) 
Last logged: 11:28:01 PM

xiaomi_miio: Error on device update!
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 365, in _async_add_entity
    await entity.async_device_update(warning=False)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 482, in async_device_update
    await task
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/vacuum.py", line 499, in update
    self.last_clean = self._device.last_clean_details()
  File "/usr/local/lib/python3.8/site-packages/miio/vacuum.py", line 381, in last_clean_details
    if not history.ids:
  File "/usr/local/lib/python3.8/site-packages/miio/vacuumcontainers.py", line 214, in ids
    return list(self.data[3])
KeyError: 3

@ferropolis
Copy link
Author

Thanks for feedback @rytilahti. Here are my log and it looks like alomst the same as AlfaJackal.

2021-04-10 23:37:37 ERROR (MainThread) [homeassistant.helpers.entity] Update for vacuum.helene_wischer fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 292, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 490, in async_device_update
    raise exc
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/vacuum.py", line 499, in update
    self.last_clean = self._device.last_clean_details()
  File "/usr/local/lib/python3.8/site-packages/miio/vacuum.py", line 381, in last_clean_details
    if not history.ids:
  File "/usr/local/lib/python3.8/site-packages/miio/vacuumcontainers.py", line 214, in ids
    return list(self.data[3])
KeyError: 3

@rytilahti
Copy link
Member

Yes, this one will be fixed when a new python-miio release is made, and the homeassistant integration gets updated.

@rytilahti rytilahti added the waiting-for-upstream We're waiting for a change upstream label Apr 10, 2021
@ferropolis
Copy link
Author

Hey @rytilahti
I know you/the team do in leisure time, therefore no stress. But did you have an idea when it could be ready? Did we talk about 1 week, 1 month or 1 year? ;) Thanks for your help again.

@ferropolis ferropolis changed the title Vaccum S7 form roborock are not detected as an new entity Vaccum Roboter S7 from roborock are not detected as an new entity Apr 19, 2021
@rytilahti
Copy link
Member

@ferropolis I'm planning to make a new release next week, so then it's just about bumping the pinned version & this should be solved for good!

@rytilahti
Copy link
Member

Sorry for the delay, I'm currently preparing the new release so let's hope we can get the bump to the next minor release!

@ferropolis
Copy link
Author

@rytilahti Thanks again, works fine for me!

@rytilahti
Copy link
Member

Glad to hear it's working @ferropolis, all thanks to @fettlaus for fixing it! :-)

@JayZiii
Copy link

JayZiii commented May 8, 2021

@ferropolis Wie hast du es geschafft ? Bei mir kommt nach dem Eintrag in der config.yaml und Neustart immernoch keine neue Entity, ich bekomme weiterhin nur den devicetracker angezeigt :/

@AlfaJackal
Copy link

@ferropolis Wie hast du es geschafft ? Bei mir kommt nach dem Eintrag in der config.yaml und Neustart immernoch keine neue Entity, ich bekomme weiterhin nur den devicetracker angezeigt :/

Die Config-Option wurde entfernt, es geht jetzt direkt über die GUI in Integrationen.

@JayZiii
Copy link

JayZiii commented May 8, 2021

@ferropolis Wie hast du es geschafft ? Bei mir kommt nach dem Eintrag in der config.yaml und Neustart immernoch keine neue Entity, ich bekomme weiterhin nur den devicetracker angezeigt :/

Die Config-Option wurde entfernt, es geht jetzt direkt über die GUI in Integrationen.

Ah klasse, okay vielen Dank dann werde ich es so nochmal versuchen :)

@github-actions github-actions bot locked and limited conversation to collaborators Jun 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
integration: xiaomi_miio waiting-for-upstream We're waiting for a change upstream
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants