Skip to content

Conversation

@damianolombardo
Copy link

No description provided.

@hsemenenko
Copy link

I am getting the following error after entering my eufy username and password.

Unexpected exception: 'device'

Traceback (most recent call last):
  File "/config/custom_components/robovac/config_flow.py", line 141, in get_eufy_vacuums
    device = tuya_client.get_device(item["device"]["id"])
                                    ~~~~^^^^^^^^^^
KeyError: 'device'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/robovac/config_flow.py", line 185, in async_step_user
    valid_data = await validate_input(self.hass, user_input)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/robovac/config_flow.py", line 167, in validate_input
    await hass.async_add_executor_job(get_eufy_vacuums, data)
  File "/usr/local/lib/python3.13/concurrent/futures/thread.py", line 59, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/robovac/config_flow.py", line 157, in get_eufy_vacuums
    item["device"]["id"]
    ~~~~^^^^^^^^^^
KeyError: 'device'

@damianolombardo
Copy link
Author

Do you get that on the master branch too? I have tested this and have another person using this branch without this issue coming up?

@hsemenenko
Copy link

I do not get the same error on the master branch. It has also been reported by someone else here: #112 (comment)

By removing ["device"] from line 141 of config_flow.py the error goes away and I can connect to the vacuum. However, it shows the status incorrectly i.e. shows cleaning when docked.

@temp
Copy link

temp commented Jul 29, 2025

Works fine here. Installed the branch from the PR, I have 2 L60's running here.
Maybe it's got something to do with that? Having a single or multiple Robovac devices?

@temp
Copy link

temp commented Jul 29, 2025

Although I have seen in another PR here (https://github.com/CodeFoodPixels/robovac/pull/64/files#diff-1a399db0f45c880538b174870af4a32a874c68567066d843c79217af7f4613b3L135) that there are also changes to devices / device inside config_flow.

@temp
Copy link

temp commented Jul 29, 2025

I'm not a python developer, but want to help - what can I do to output the item array?

@temp
Copy link

temp commented Jul 29, 2025

Ok, found it. Code is only executed on config. This is the structure from device_response:

{
  "res_code": 1,
  "message": "",
  "devices": [
    {
      "id": "...",
      ...
    },{
      "id": "...",
    }
  ]
}

So yes, the ["device"] should be removed. Also on lines 157 and 160.

kevinbird15 referenced this pull request in kevinbird15/robovac-ha-integration Sep 6, 2025
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
@PixNyb
Copy link

PixNyb commented Oct 1, 2025

Would this also include support for the L60 hybrid? Since this also does mopping i assume some additional changes are required. If not i'd be happy to pick it up as a separate PR

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

Successfully merging this pull request may close these issues.