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

Integration is not working with HA 2023.10.1 #510

Open
MiguelCosta opened this issue Oct 10, 2023 · 117 comments
Open

Integration is not working with HA 2023.10.1 #510

MiguelCosta opened this issue Oct 10, 2023 · 117 comments

Comments

@MiguelCosta
Copy link

MiguelCosta commented Oct 10, 2023

Version of the custom_component

1.0.12

What vacuum are you using?

Roborock S7

Describe the bug

The 1.0.12 integration version works with HA 2023.10.0, but after upgrade HA to 2023.10.1, the integration is not working anymore.
The master version is also not working.

Debug log


Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 399, in async_setup
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/roborock/__init__.py", line 44, in async_setup_entry
    user_data = UserData.from_dict(data.get("user_data"))
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/roborock/containers.py", line 90, in from_dict
    return from_dict(cls, decamelize_obj(data, ignore_keys), config=Config(cast=[Enum]))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 68, in from_dict
    raise WrongTypeError(field_path=field.name, field_type=field.type, value=value)
dacite.exceptions.WrongTypeError: wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': 'XXXXXXXXXXXXX', 's': 'XXXXXXXX', 'h': 'XXXXXXXX', 'k': 'XXXXXXX', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu-4.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"

@MiguelCosta MiguelCosta changed the title Integration it not working with HA 2023.10.1 Integration is not working with HA 2023.10.1 Oct 10, 2023
@subexx
Copy link

subexx commented Oct 11, 2023

I have the same issue

@matt1131
Copy link

Same

@matt1131
Copy link

Nevermind, updated version works

@tretabyte
Copy link

which updated version?

@matt1131
Copy link

Double nevermind, looks like it didn't. I'm on 1.0.12


This error originated from a custom integration.

Logger: homeassistant
Source: custom_components/roborock/time.py:60
Integration: Roborock (documentation, issues)
First occurred: 21:19:18 (2 occurrences)
Last logged: 21:19:48

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 882, in _update_entity_states
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 750, in async_update_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 879, in _async_write_ha_state
    state, attr = self._async_generate_attributes()
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 820, in _async_generate_attributes
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 785, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/time/__init__.py", line 94, in state
    if self.native_value is None:
       ^^^^^^^^^^^^^^^^^
  File "/config/custom_components/roborock/time.py", line 188, in native_value
    return self.entity_description.get_value(self.api.cache.get(self.entity_description.cache_key))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/roborock/time.py", line 60, in <lambda>
    get_value=lambda cache: datetime.time(
                            ^^^^^^^^^^^^^^
TypeError: 'NoneType' object cannot be interpreted as an integer

@MiguelCosta
Copy link
Author

I am using HA 2023.10.3 and the integration continues with same error :-(

Logger: homeassistant.config_entries
Source: config_entries.py:399
First occurred: 16:44:18 (1 occurrences)
Last logged: 16:44:18

Error setting up entry miguelpintodacosta@gmail.com for roborock
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 399, in async_setup
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/roborock/__init__.py", line 44, in async_setup_entry
    user_data = UserData.from_dict(data.get("user_data"))
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/roborock/containers.py", line 90, in from_dict
    return from_dict(cls, decamelize_obj(data, ignore_keys), config=Config(cast=[Enum]))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 68, in from_dict
    raise WrongTypeError(field_path=field.name, field_type=field.type, value=value)
dacite.exceptions.WrongTypeError: wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': 'XXXXXXX', 's': 'XXXXXXX', 'h': 'XXXXXXX', 'k': 'XXXXXXX', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu-4.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"

@TB-SE
Copy link

TB-SE commented Oct 14, 2023

+1

@superpower10
Copy link

I think something changed in getting the robots in Home Assistant 2023.10 (.0 to .3)

I deinstalled this integration in HACS and rebooted the pi and tried it with the build integration which doesn't work either anymore (unknown error).

Then I installed this integration over HACS again and tried to add the robots. Here comes the message that no robot is assigned to the account:

Bildschirmfoto 2023-10-14 um 11 00 53

@ChristophGoth
Copy link

+1

@eXenic
Copy link

eXenic commented Oct 14, 2023

+1

image

@mesut3000
Copy link

Same

@jyug
Copy link

jyug commented Oct 15, 2023

same No device found error

@rain82k
Copy link

rain82k commented Oct 15, 2023

Same :(

@TB-SE
Copy link

TB-SE commented Oct 15, 2023

Mine seems to work randomly between reboots and generally tends to fix itself when I start the vacuum via the Roborock app on my phone.

@markrennie71
Copy link

I updated HA and this integration today, HA kept rebooting and wouldn't load properly. I had to rename the Roborock folder to get it to load.

@markaggar
Copy link

I installed the latest update via HACS that was posted today. Fixed the problem for me.

@ChristophGoth
Copy link

No change for me with latest main "release"

@markrennie71
Copy link

Working perfectly again for me now. Thank you

@Nordikk
Copy link

Nordikk commented Oct 18, 2023

Does still not work for me.

Same log messages as @MiguelCosta and error "No device found within your Roborock account"

@neuroverflow
Copy link

neuroverflow commented Oct 19, 2023

I switched to the main branch, reboot, not working.
Went back to the last (despite it was the one I was using) and reboot to make it work.

Never deleted the integration. I suspect that a sinple reinstall to force dependencies would had the same effect.

Edit: didn't survived a restart :(

@fherreror
Copy link

Same here.
I installed last version from HACs and the problem persists.

@Sirmike2
Copy link

Also same problem.

@hyperpm
Copy link

hyperpm commented Oct 22, 2023

I have the same issue! "No device found within your Roborock account"! I'm about to tear out my hair, at least what's left of it...

@AlexHowser
Copy link

Same Problem here :(

@Kesslermeinname
Copy link

Even with HA 2023.10.5, deleted and reinstalled integration and restart the whole serve the problem still exists.

Is it a HA problem? Because I can’t even get my robot in through the official integration.

@markaggar
Copy link

markaggar commented Oct 23, 2023

Still working for me. I'm wondering if the roborock region has something to do with the problem others are still having. I'm in the US, again works fine. The recent logs posted were connecting to the EU roborock cloud.

@Bastian007
Copy link

I had the same issue and went back in HACS from "1.0.12" to version "main"; after reboot everything works as before.
image

@Kesslermeinname
Copy link

Still working for me. I'm wondering if the roborock region has something to do with the problem others are still having. I'm in the US, again works fine. The recent logs posted were connecting to the EU roborock cloud.

I’m a EU citizen…maybe the dev can tell us more about that. Like I said, even the HA own integration fails to initiate the robot.

@subexx
Copy link

subexx commented Oct 23, 2023

Updated to 1.0.12 and it started working for me.

@fherreror
Copy link

@Kesslermeinname If you have a problem you should always read the hole thread.

You need the „Advanced SSH & Web Terminal“ Add-On (can be installed over the Add-On Store). Start it and open it.

Type: pip show dacite (see here #510 (comment))

you miss a step. you have to access the home assistant docker container. you have to open the add-on with safe mode off and then:
docker exec -it homeassistant bash

only after that you can use pip show dacite

@Kesslermeinname
Copy link

@Kesslermeinname If you have a problem you should always read the hole thread.
You need the „Advanced SSH & Web Terminal“ Add-On (can be installed over the Add-On Store). Start it and open it.
Type: pip show dacite (see here #510 (comment))

you miss a step. you have to access the home assistant docker container. you have to open the add-on with safe mode off and then: docker exec -it homeassistant bash

only after that you can use pip show dacite

Okay…I’m using HA in Virtual Box on a Mac. So not directly docker 😅

@fherreror
Copy link

@Kesslermeinname If you have a problem you should always read the hole thread.
You need the „Advanced SSH & Web Terminal“ Add-On (can be installed over the Add-On Store). Start it and open it.
Type: pip show dacite (see here #510 (comment))

you miss a step. you have to access the home assistant docker container. you have to open the add-on with safe mode off and then: docker exec -it homeassistant bash
only after that you can use pip show dacite

Okay…I’m using HA in Virtual Box on a Mac. So not directly docker 😅

it does not matter, even HA OS uses docker internally. So if you didn't use first that command should probably be the cause that dacite didn't show in your case

@Lash-L
Copy link
Collaborator

Lash-L commented Nov 2, 2023

You can also try the command ha core rebuild after remove govee hacs or modifying its manifest

@p1ranha
Copy link

p1ranha commented Nov 2, 2023

For all getting the missing devices with dacite 1.8.1 - double check your password. The same error message appears if you type wrong password.
I now updated to hassio 2023.11, removed goove (previously disabled only), installed govee lan and now everything works.

@Kesslermeinname
Copy link

@Kesslermeinname If you have a problem you should always read the hole thread.
You need the „Advanced SSH & Web Terminal“ Add-On (can be installed over the Add-On Store). Start it and open it.
Type: pip show dacite (see here #510 (comment))

you miss a step. you have to access the home assistant docker container. you have to open the add-on with safe mode off and then: docker exec -it homeassistant bash
only after that you can use pip show dacite

Okay…I’m using HA in Virtual Box on a Mac. So not directly docker 😅

it does not matter, even HA OS uses docker internally. So if you didn't use first that command should probably be the cause that dacite didn't show in your case

Weird thing…I have shut down HA by Terminal, restarted the Server and tadaaaa…my robot works again?! I mean, I have tried to shut down HA completely from the standard menu and also restarted the server serval times but this time, it worked. That’s freaky 🤓

@inertia666
Copy link

For all getting the missing devices with dacite 1.8.1 - double check your password. The same error message appears if you type wrong password. I now updated to hassio 2023.11, removed goove (previously disabled only), installed govee lan and now everything works.

Neither password or email code is working for me. Dacite 1.8.1

@Lash-L
Copy link
Collaborator

Lash-L commented Nov 17, 2023

For all getting the missing devices with dacite 1.8.1 - double check your password. The same error message appears if you type wrong password. I now updated to hassio 2023.11, removed goove (previously disabled only), installed govee lan and now everything works.

Neither password or email code is working for me. Dacite 1.8.1

Logs please. You are having a different issue

@inertia666
Copy link

inertia666 commented Nov 20, 2023

For all getting the missing devices with dacite 1.8.1 - double check your password. The same error message appears if you type wrong password. I now updated to hassio 2023.11, removed goove (previously disabled only), installed govee lan and now everything works.

Neither password or email code is working for me. Dacite 1.8.1

Logs please. You are having a different issue

2023-11-17 09:35:37.675 ERROR (MainThread) [custom_components.roborock.config_flow] wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': '', 's': '', 'h': '', 'k': '', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"
hanew_1 | Traceback (most recent call last):
hanew_1 | File "/config/custom_components/roborock/config_flow.py", line 228, in _code_login
hanew_1 | login_data = await self._client.code_login(code)
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | File "/usr/local/lib/python3.11/site-packages/roborock/api.py", line 660, in code_login
hanew_1 | return UserData.from_dict(user_data)
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | File "/usr/local/lib/python3.11/site-packages/roborock/containers.py", line 90, in from_dict
hanew_1 | return from_dict(cls, decamelize_obj(data, ignore_keys), config=Config(cast=[Enum]))
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 68, in from_dict
hanew_1 | if config.check_types and not is_instance(value, field_type):
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | dacite.exceptions.WrongTypeError: wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': '', 's': '', 'h': '', 'k': '', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"

I posted this log in another thread but here it is here as well. I have removed the values in json for identification purposes

@Lash-L
Copy link
Collaborator

Lash-L commented Nov 20, 2023

For all getting the missing devices with dacite 1.8.1 - double check your password. The same error message appears if you type wrong password. I now updated to hassio 2023.11, removed goove (previously disabled only), installed govee lan and now everything works.

Neither password or email code is working for me. Dacite 1.8.1

Logs please. You are having a different issue

2023-11-17 09:35:37.675 ERROR (MainThread) [custom_components.roborock.config_flow] wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': '', 's': '', 'h': '', 'k': '', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"

hanew_1 | Traceback (most recent call last):

hanew_1 | File "/config/custom_components/roborock/config_flow.py", line 228, in _code_login

hanew_1 | login_data = await self._client.code_login(code)

hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

hanew_1 | File "/usr/local/lib/python3.11/site-packages/roborock/api.py", line 660, in code_login

hanew_1 | return UserData.from_dict(user_data)

hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

hanew_1 | File "/usr/local/lib/python3.11/site-packages/roborock/containers.py", line 90, in from_dict

hanew_1 | return from_dict(cls, decamelize_obj(data, ignore_keys), config=Config(cast=[Enum]))

hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

hanew_1 | File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 68, in from_dict

hanew_1 | if config.check_types and not is_instance(value, field_type):

hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

hanew_1 | dacite.exceptions.WrongTypeError: wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': '', 's': '', 'h': '', 'k': '', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"

I posted this log in another thread but here it is here as well. I have removed the values in json for identification purposes

You still do not have the right version of dacite - that's what that error means.

@inertia666
Copy link

inertia666 commented Nov 21, 2023

For all getting the missing devices with dacite 1.8.1 - double check your password. The same error message appears if you type wrong password. I now updated to hassio 2023.11, removed goove (previously disabled only), installed govee lan and now everything works.

Neither password or email code is working for me. Dacite 1.8.1

Logs please. You are having a different issue

2023-11-17 09:35:37.675 ERROR (MainThread) [custom_components.roborock.config_flow] wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': '', 's': '', 'h': '', 'k': '', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"
hanew_1 | Traceback (most recent call last):
hanew_1 | File "/config/custom_components/roborock/config_flow.py", line 228, in _code_login
hanew_1 | login_data = await self._client.code_login(code)
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | File "/usr/local/lib/python3.11/site-packages/roborock/api.py", line 660, in code_login
hanew_1 | return UserData.from_dict(user_data)
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | File "/usr/local/lib/python3.11/site-packages/roborock/containers.py", line 90, in from_dict
hanew_1 | return from_dict(cls, decamelize_obj(data, ignore_keys), config=Config(cast=[Enum]))
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 68, in from_dict
hanew_1 | if config.check_types and not is_instance(value, field_type):
hanew_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1 | dacite.exceptions.WrongTypeError: wrong value type for field "rriot" - should be "roborock.containers.RRiot | None" instead of value "{'u': '', 's': '', 'h': '', 'k': '', 'r': {'r': 'EU', 'a': 'https://api-eu.roborock.com', 'm': 'ssl://mqtt-eu.roborock.com:8883', 'l': 'https://wood-eu.roborock.com'}}" of type "dict"
I posted this log in another thread but here it is here as well. I have removed the values in json for identification purposes

You still do not have the right version of dacite - that's what that error means.

Now for some reason the dacite version is 1.8.0

Name: dacite
Version: 1.8.0
Summary: Simple creation of data classes from dictionaries.
Home-page: https://github.com/konradhalas/dacite
Author: Konrad Hałas
Author-email: halas.konrad@gmail.com
License: MIT
Location: /usr/local/lib/python3.11/site-packages
Requires:
Required-by: brother, gios, govee-api-laggat, home-assistant-chip-clusters, nettigo-air-monitor, python-matter-server, python-roborock

But i have removed the roborock and installed xioami miio instead after pairing the roborock with xiomi home. Maybe that has changed the dacite version?

I only need minimum functionality and the ability to read the status so can live without the map.

@saschabrockel
Copy link

@chriske I understand, however as a h6199 owner (not lan controls supported device) I dont have such an option, which is shame, because I would prefer local control 1000 times more. You are right, that repository isnt maintained, therefore I forked it, bud didnt have luck to bump dacite version there, as it would return some error while adding device. Maybe it just needs more love from me, but my time is problem here.

Same here: The light strings outdoors, don't support local LAN API... :-/

@chriske I understand, however as a h6199 owner (not lan controls supported device) I dont have such an option, which is shame, because I would prefer local control 1000 times more. You are right, that repository isnt maintained, therefore I forked it, but didnt have luck to bump dacite version there, as it would return some error while adding device. Maybe it just needs more love from me, but my time is problem here.

Not really. Govee Lan integration uses the cloud for the devices with no LAN. I use H6199 and I can use it

Lol, I have waited a month for a fix and was watching this issue and this just fixed it. Goddamn govee integration.

@bddckr
Copy link

bddckr commented Nov 22, 2023

The just-released latest version of the govee integration resolves the problem for me.

@inertia666
Copy link

The just-released latest version of the govee integration resolves the problem for me.

Updated that, reinstalled the Roborock addon. Dacite version is 1.8.0...device not found.

Traceback (most recent call last):
hanew_1  |   File "/config/custom_components/roborock/config_flow.py", line 239, in _pass_login
hanew_1  |     login_data = await self._client.pass_login(password)
hanew_1  |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/roborock/api.py", line 628, in pass_login
hanew_1  |     return UserData.from_dict(user_data)
hanew_1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/roborock/containers.py", line 90, in from_dict
hanew_1  |     return from_dict(cls, decamelize_obj(data, ignore_keys), config=Config(cast=[Enum]))
hanew_1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 64, in from_dict
hanew_1  |     value = _build_value(type_=field_type, data=field_data, config=config)
hanew_1  |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 101, in _build_value
hanew_1  |     if is_subclass(type_, cast_type):
hanew_1  |        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/types.py", line 168, in is_subclass
hanew_1  |     if is_generic_collection(sub_type):
hanew_1  |        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/types.py", line 147, in is_generic_collection
hanew_1  |     origin = extract_origin_collection(type_)
hanew_1  |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/types.py", line 24, in extract_origin_collection
hanew_1  |     return collection.__origin__
hanew_1  |            ^^^^^^^^^^^^^^^^^^^^^
hanew_1  | AttributeError: 'types.UnionType' object has no attribute '__origin__'
hanew_1  | 2023-11-23 10:26:33.100 ERROR (MainThread) [custom_components.roborock.config_flow] 'types.UnionType' object has no attribute '__origin__'
hanew_1  | Traceback (most recent call last):
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/types.py", line 22, in extract_origin_collection
hanew_1  |     return collection.__extra__
hanew_1  |            ^^^^^^^^^^^^^^^^^^^^
hanew_1  | AttributeError: 'types.UnionType' object has no attribute '__extra__'
hanew_1  |
hanew_1  | During handling of the above exception, another exception occurred:
hanew_1  |
hanew_1  | Traceback (most recent call last):
hanew_1  |   File "/config/custom_components/roborock/config_flow.py", line 228, in _code_login
hanew_1  |     login_data = await self._client.code_login(code)
hanew_1  |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/roborock/api.py", line 660, in code_login
hanew_1  |     return UserData.from_dict(user_data)
hanew_1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/roborock/containers.py", line 90, in from_dict
hanew_1  |     return from_dict(cls, decamelize_obj(data, ignore_keys), config=Config(cast=[Enum]))
hanew_1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 64, in from_dict
hanew_1  |     value = _build_value(type_=field_type, data=field_data, config=config)
hanew_1  |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/core.py", line 101, in _build_value
hanew_1  |     if is_subclass(type_, cast_type):
hanew_1  |        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/types.py", line 168, in is_subclass
hanew_1  |     if is_generic_collection(sub_type):
hanew_1  |        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/types.py", line 147, in is_generic_collection
hanew_1  |     origin = extract_origin_collection(type_)
hanew_1  |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
hanew_1  |   File "/usr/local/lib/python3.11/site-packages/dacite/types.py", line 24, in extract_origin_collection
hanew_1  |     return collection.__origin__

Tested both password and code login

@Gerap93
Copy link

Gerap93 commented Nov 24, 2023

Hi, same here I have HACS Govee integration with Dacite 1.8.0

When trying to add a roborock backup it fails to adding on de email verifiaction code.

image

*Unexpected Error

Theres is no way to fix it without uninstalling HAGS Govee?

Thanks!

@inertia666
Copy link

inertia666 commented Nov 24, 2023

Hi, same here I have HACS Govee integration with Dacite 1.8.0

When trying to add a roborock backup it fails to adding on de email verifiaction code.

image

*Unexpected Error

Theres is no way to fix it without uninstalling HAGS Govee?

Thanks!

Depending on what you need from the addon, you can try the xiaomi miio and pair your robot to the xiaomi home app. It has exactly the same GUI in the this app as the roborock app. Might be worth using temporarily until this is sorted out.

@Lash-L
Copy link
Collaborator

Lash-L commented Nov 24, 2023

Do the following and it should fix it:

  1. uninstall govee hacs
  2. restart
  3. install latest govee hacs or govee lan
  4. restart
  5. install latest roborock version (0.1.3)
    6)restart

@egoogins
Copy link

@Lash-L - Thank you, I had the same issue as everyone else and the above steps solved it for me!

@aductran
Copy link

Do the following and it should fix it:

  1. uninstall govee hacs
  2. restart
  3. install latest govee hacs or govee lan
  4. restart
  5. install latest roborock version (0.1.3)
    6)restart

Had the same issue and followed your steps. Everything is back to normal. Thanks!

@inertia666
Copy link

Working now with Govee lan and 0.13. Thanks.

@R8s6
Copy link

R8s6 commented Nov 28, 2023

I don't have govee or dacite, but it failed as well.

I tried:
upgrading the integration to 1.0.13
redownloading it
removing and adding the integration again.
none worked.

Thanks!

2023-11-28 11:50:20.066 WARNING (SyncWorker_3) [homeassistant.loader] We found a custom integration roborock which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2023-11-28 11:50:46.400 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:51:07.686 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:51:39.005 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:52:07.303 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:52:33.731 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:53:05.308 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:53:46.970 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:54:48.974 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:56:30.809 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:58:12.576 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 11:59:54.365 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 12:01:36.242 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 12:03:18.561 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 12:05:01.039 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 12:06:41.283 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 12:07:07.485 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 12:07:38.738 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
2023-11-28 12:08:20.500 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo
Logger: homeassistant.config_entries
Source: config_entries.py:2069
First occurred: 12:13:36 (1 occurrences)
Last logged: 12:13:36

Error occurred loading flow for integration roborock: cannot import name 'async_process_integration_platform_for_component' from 'homeassistant.helpers.integration_platform' (/usr/src/homeassistant/homeassistant/helpers/integration_platform.py)
Logger: homeassistant.setup
Source: setup.py:215
First occurred: 12:13:16 (1 occurrences)
Last logged: 12:13:16

Setup failed for custom integration roborock: Unable to import component: cannot import name 'async_process_integration_platform_for_component' from 'homeassistant.helpers.integration_platform' (/usr/src/homeassistant/homeassistant/helpers/integration_platform.py)
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/setup.py", line 215, in _async_setup_component
    component = integration.get_component()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 818, in get_component
    ComponentProtocol, importlib.import_module(self.pkg_path)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/config/custom_components/roborock/__init__.py", line 11, in <module>
    from homeassistant.helpers.integration_platform import (
ImportError: cannot import name 'async_process_integration_platform_for_component' from 'homeassistant.helpers.integration_platform' (/usr/src/homeassistant/homeassistant/helpers/integration_platform.py)

@Lash-L
Copy link
Collaborator

Lash-L commented Nov 28, 2023

I don't have govee or dacite, but it failed as well.

I tried:

upgrading the integration to 1.0.13

redownloading it

removing and adding the integration again.

none worked.

Thanks!


2023-11-28 11:50:20.066 WARNING (SyncWorker_3) [homeassistant.loader] We found a custom integration roborock which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant

2023-11-28 11:50:46.400 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:51:07.686 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:51:39.005 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:52:07.303 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:52:33.731 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:53:05.308 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:53:46.970 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:54:48.974 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:56:30.809 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:58:12.576 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 11:59:54.365 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 12:01:36.242 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 12:03:18.561 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 12:05:01.039 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 12:06:41.283 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 12:07:07.485 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 12:07:38.738 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo

2023-11-28 12:08:20.500 WARNING (MainThread) [custom_components.roborock] Failing setting up device 2Rn4r188WctTMsZr67H0lo


Logger: homeassistant.config_entries

Source: config_entries.py:2069

First occurred: 12:13:36 (1 occurrences)

Last logged: 12:13:36



Error occurred loading flow for integration roborock: cannot import name 'async_process_integration_platform_for_component' from 'homeassistant.helpers.integration_platform' (/usr/src/homeassistant/homeassistant/helpers/integration_platform.py)


Logger: homeassistant.setup

Source: setup.py:215

First occurred: 12:13:16 (1 occurrences)

Last logged: 12:13:16



Setup failed for custom integration roborock: Unable to import component: cannot import name 'async_process_integration_platform_for_component' from 'homeassistant.helpers.integration_platform' (/usr/src/homeassistant/homeassistant/helpers/integration_platform.py)

Traceback (most recent call last):

  File "/usr/src/homeassistant/homeassistant/setup.py", line 215, in _async_setup_component

    component = integration.get_component()

                ^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/usr/src/homeassistant/homeassistant/loader.py", line 818, in get_component

    ComponentProtocol, importlib.import_module(self.pkg_path)

                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/usr/local/lib/python3.11/importlib/__init__.py", line 126, in import_module

    return _bootstrap._gcd_import(name[level:], package, level)

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import

  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load

  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked

  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked

  File "<frozen importlib._bootstrap_external>", line 940, in exec_module

  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed

  File "/config/custom_components/roborock/__init__.py", line 11, in <module>

    from homeassistant.helpers.integration_platform import (

ImportError: cannot import name 'async_process_integration_platform_for_component' from 'homeassistant.helpers.integration_platform' (/usr/src/homeassistant/homeassistant/helpers/integration_platform.py)

Try updating your home assistant

@Makzimalist
Copy link

Do the following and it should fix it:

  1. uninstall govee hacs
  2. restart
  3. install latest govee hacs or govee lan
  4. restart
  5. install latest roborock version (0.1.3)
    6)restart

FINALLY all is back to normal. thanks!

@iceman73
Copy link

This fixed my issue as well

@R8s6
Copy link

R8s6 commented Dec 1, 2023

I don't have govee or dacite, but it failed as well.

I tried: upgrading the integration to 1.0.13 redownloading it removing and adding the integration again. none worked.

Thanks!

I upgraded the OS and core to latest version, updated the Roborock integration to 1.0.13, it didn't work at first, but i removed the device, then added it again, and now it works.

Thanks for the fix!

@tsrubar
Copy link

tsrubar commented Dec 6, 2023

@tsrubar your solution is temporary. After the next home assistant upgrade the container will be recreated and your modification will be gone. It should be fixed on the govee integration side unfortunately, which is not maintained as it seems. I switched to govee lan integration, it works and it is actively developed.

Actually it persisted until roborock custom integration upgrade, since manifest file changes only then :) Anyway, I had to do it again, because latest 1.0.13 comes with dacite==1.8.0 and it stopped working again even with this version on 2023.11.3, which works with 1.8.1

@Gerap93
Copy link

Gerap93 commented Dec 6, 2023

Hi, same here I have HACS Govee integration with Dacite 1.8.0
When trying to add a roborock backup it fails to adding on de email verifiaction code.
image
*Unexpected Error
Theres is no way to fix it without uninstalling HAGS Govee?
Thanks!

Depending on what you need from the addon, you can try the xiaomi miio and pair your robot to the xiaomi home app. It has exactly the same GUI in the this app as the roborock app. Might be worth using temporarily until this is sorted out.

That's what I did, thanks!

Anyone knows if the 11.2 update fixed it? It brings some new roborock functions..

@Mr-HaleYa
Copy link

This works great for anyone having the issue. You can modify the files yourself until the pull goes through. Modify, restart, and the integration works.
LaggAt/hacs-govee#148

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

No branches or pull requests