core
core copied to clipboard
Roborock: User agreement must be accepted again
The problem
System details:
- Core 2024.9.2
- Supervisor 2024.09.1
- Operating System 13.1
- Frontend 20240909.1
When trying to setup Roborock integration, entering the email and Verification code, the setup wizard throws an error: "There was an unknown roborock exception - please check your logs.".
The system is a fresh install with only a couple of integrations configured.
What version of Home Assistant Core has the issue?
2024.9.2
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant Core
Integration causing the issue
Roborock
Link to integration documentation on our website
https://www.home-assistant.io/integrations/roborock
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Logger: homeassistant.components.roborock.config_flow
Source: components/roborock/config_flow.py:109
integration: Roborock (documentation, issues)
First occurred: 20:15:56 (1 occurrences)
Last logged: 20:15:56
Unexpected exception
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/roborock/config_flow.py", line 109, in async_step_code
login_data = await self._client.code_login(code)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/roborock/web_api.py", line 172, in code_login
raise RoborockInvalidUserAgreement(
roborock.exceptions.RoborockInvalidUserAgreement: User agreement must be accepted again - or you are attempting to use the Mi Home app account.
Additional information
No response
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 closeCloses the issue.@home-assistant rename Awesome new titleRenames the issue.@home-assistant reopenReopen the issue.@home-assistant unassign roborockRemoves the current integration label and assignees on the issue, add the integration domain after the command.@home-assistant add-label needs-more-informationAdd a label (needs-more-information, problem in dependency, problem in custom component) to the issue.@home-assistant remove-label needs-more-informationRemove 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)
Hey @eins2,
i just had the same problem. I got the solution for you:
Login to your Roborock App - Either you get a prompt to accept the User Agreement or you have to manually go to this path in your roborock app: Profile -> About Us -> User Agreement and accept it there. Hope that helps.
Next steps are probably (1) update the error handling to handle this case and render an error message (2) update the documentation with instructions to resolve.
Hey @eins2,
i just had the same problem. I got the solution for you:
Login to your Roborock App - Either you get a prompt to accept the User Agreement or you have to manually go to this path in your roborock app: Profile -> About Us -> User Agreement and accept it there. Hope that helps.
This work around does not work for me. The user agreement was already accepted. I am getting the same error as the OP.
I used the Mi Home app to control my vacuum cleaner and encountered the same error. After downloading the Roborock app and logging in, I was asked to accept the User Agreement. I accepted it, and everything started working. Therefore, use the Roborock app to fix this issue.
I am not getting the verification code. I have already accepted the new terms. How can I get the verification code?
I am not getting the verification code. I have already accepted the new terms. How can I get the verification code?
Updating HA and then restarting fixed the problem for me
This is doing the same on mine. I've accepted the user agreement, revoked and then re-accepted, and updated and restarted HA. Still the same issue: Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/roborock/config_flow.py", line 109, in async_step_code login_data = await self._client.code_login(code) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.13/site-packages/roborock/web_api.py", line 172, in code_login raise RoborockInvalidUserAgreement( "User agreement must be accepted again - or you are attempting to use the Mi Home app account." ) roborock.exceptions.RoborockInvalidUserAgreement: User agreement must be accepted again - or you are attempting to use the Mi Home app account.
Quoting from one of the other duplicate issues:
For me, I had to revoke my current user agreement in the app (Profile -> About Us -> User Agreement), log in again, accept new agreement, and finally, restart HA.
As a user I would expect that this error is caught and explained in the UI. Maybe even with a link to a resolution of something self-heal.
Currently I need to dive into the logs to find that cause.
@chris400 yes, that's what we said above https://github.com/home-assistant/core/issues/126288#issuecomment-2381413173 and has now been fixed.