core
core copied to clipboard
Can't onboard due to error when trying to save analytics settings
The problem
I've installed home assistant into a docker dev container in windows. After running te setup script and starting HA using the VSCode command I get an error during onboarding, when i'm trying to save the analytics settings:
Ha logs are stating:
2024-09-20 07:08:54.072 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140536065919008] Error handling message: Unknown error (unknown_error) Rudolf from 172.17.0.1 (Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36) Traceback (most recent call last): File "/workspaces/home-assistant-core/homeassistant/components/websocket_api/decorators.py", line 28, in _handle_async_response await func(hass, connection, msg) File "/workspaces/home-assistant-core/homeassistant/components/analytics/init.py", line 93, in websocket_analytics_preferences await analytics.send_analytics() File "/workspaces/home-assistant-core/homeassistant/components/analytics/analytics.py", line 180, in send_analytics supervisor_client = hassio.get_supervisor_client(hass) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/workspaces/home-assistant-core/homeassistant/components/hassio/handler.py", line 615, in get_supervisor_client hassio: HassIO = hass.data[DOMAIN] ~~~~~~~~~^^^^^^^^ KeyError: 'hassio'
What version of Home Assistant Core has the issue?
dev commit baa7930
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
onboarding
Link to integration documentation on our website
https://www.home-assistant.io/getting-started/onboarding/
Diagnostics information
N.A.
Example YAML snippet
N.A.
Anything in the logs that might be useful for us?
2024-09-20 07:08:54.072 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140536065919008] Error handling message: Unknown error (unknown_error) Rudolf from 172.17.0.1 (Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36)
Traceback (most recent call last):
File "/workspaces/home-assistant-core/homeassistant/components/websocket_api/decorators.py", line 28, in _handle_async_response
await func(hass, connection, msg)
File "/workspaces/home-assistant-core/homeassistant/components/analytics/__init__.py", line 93, in websocket_analytics_preferences
await analytics.send_analytics()
File "/workspaces/home-assistant-core/homeassistant/components/analytics/analytics.py", line 180, in send_analytics
supervisor_client = hassio.get_supervisor_client(hass)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspaces/home-assistant-core/homeassistant/components/hassio/handler.py", line 615, in get_supervisor_client
hassio: HassIO = hass.data[DOMAIN]
~~~~~~~~~^^^^^^^^
KeyError: 'hassio'
Additional information
Looks like it's caused by this commit: https://github.com/home-assistant/core/commit/97d0d91d2c464a7a8474e6035969116b70631e65#diff-03f6e0587e16904de455b267984c7e2379ce1a6231ae994ed5bcca7372a386b0R613
Ho exactly did you start HA? Did you follow any guide? Further, I guess there are much more messages in your log, before this error - please provide the full log, thx :+1:
Actually, there are not more error messages, or related log messages. I'm not sure what to tell more about the startup. I'm running vscode in windows. I have a fork of the core repo with the latest commit. I use the procedure as defined in the documentation for starting a new development environment. Installation goed well. I go to localhost:8123 and the on-boarding process is starting. As soon as I arrive on the page for analytics settings I'm trying to save the settings the error appears.
Every time I push the 'volgende' button, one error message is added to the log, the one I mentioned.
Don't really know what to tell more...
I can confirm. Followed the setup steps here Workaround is to checkout commit before the one mentioned, finish onboarding, pull latest.
Hey there @home-assistant/core, @ludeeus, mind taking a look at this issue as it has been labeled with an integration (analytics) you are listed as a code owner for? Thanks!
Code owner commands
Code owners of analytics 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 analyticsRemoves 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)
analytics documentation analytics source (message by IssueLinks)