home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
73.56k stars 30.74k forks source link

Post 2024.8 - history data not being displayed after HA restarts - "Loading state history" or spinning progress bar. Resolves after some time. #123362

Open snigehere opened 3 months ago

snigehere commented 3 months ago

The problem

Clicking on an entity gets me the device info where, on some pages the history graph is correctly shown and on others I get "loading state history". If I click "show more" to view a wider timeframe I just get a spinning disk.

image

What version of Home Assistant Core has the issue?

core-2024.8.0

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

/history

Link to integration documentation on our website

https://www.home-assistant.io/integrations/history/

Diagnostics information

n/a

Example YAML snippet

n/a

Anything in the logs that might be useful for us?

no messages in the log related to database or history

Additional information

No response

home-assistant[bot] commented 3 months ago

Hey there @home-assistant/core, mind taking a look at this issue as it has been labeled with an integration (history) you are listed as a code owner for? Thanks!

Code owner commands Code owners of `history` can trigger bot actions by commenting: - `@home-assistant close` Closes the issue. - `@home-assistant rename Awesome new title` Renames the issue. - `@home-assistant reopen` Reopen the issue. - `@home-assistant unassign history` Removes the current integration label and assignees on the issue, add the integration domain after the command. - `@home-assistant add-label needs-more-information` Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue. - `@home-assistant remove-label needs-more-information` Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


history documentation history source (message by IssueLinks)

snigehere commented 3 months ago

no history graphs are rendering ... I left it for 20 minutes - no errors in the log

image

snigehere commented 3 months ago

I wondered if the database update was still being applied but when I look at table schema_changes at change number 44 I assume its completed as there is a timestamp in the changed column.

snigehere commented 3 months ago

So after around 3 to 4 hours the history data started being displayed in history graphs however after re-booting Home Assistant I am back to the same issue. I assume some indexing may be going on which is taking way more than it should

tarmor1 commented 3 months ago

I had the same issue but it took way less time (ca 60 minutes), History not being displayed and carousel turning. On top of that, I had missing the units (W or degC) next to the values on cards. It healed itself. Will try soon if it re-occurs with restart.

issue-triage-workflows[bot] commented 2 days ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.