There is a statistics tab that contains a relatively small subset of my entities (30 out of hundreds [too many to count] of available sensor entities) and very few of these statistics sensors additionally have a small graph icon on the right to open a historic values manipulation dialog.
Questions:
Which property of a sensor makes it appear in the “statistics” tab?
What can I do with sensors in the statistics tab that I cannot do with all my other sensors?
Which additional property makes it have the graph icon to manipulate historic data?
Which property makes it store data for more than two weeks?
additional question:
I have 4 sensors on the statistics tab with a complaint about “unsupported state class”. They actually do not have any state class set at all, but since many of my sensors do not have a state class I assume this fact alone is not an error, but why are they appearing on the “statistics” tab where a missing state class seems to be a problem?
The problematic entries are created by the mobile App integration, namely battery level and battery temperature.
Meanwhile I have tried clicking the “reload” menu item for both mobiles on the integrations page in the “mobile app” integration and half an hour later suddenly for one of the two phones the error message disappeared. It seems the sensors for my phone now suddenly gained a state class “measurement” property while the same sensors from my wife’s phone still have no state class property. I’m going to wait some more time to see what happens. Maybe the “reload” did the trick.
I cannot imagine who would have removed the state class entity because these sensors are created by integration and there is no way to influence them, this must have been a bug in one of the recent versions.
Because of the missing state class I wondered whether there might be some other circumstance that forced them into the statistics tab without having the required state class, that’s why i asked the question. This entire “statistics” vs. “long term statistics” (same thing?) vs. recorder subject is still a bit confusing to me.
Interesting. Neither of my iPhone battery sensors have a state_class and they don’t appear in Dev Tools Stats with an issue. So they never have had a state_class.
Did you use customize to add this attribute to the sensors?
I have not changed or configured anything with regard to these sensors. I only saw it by accident today while clicking through the available tabs in this section and there were 4 sensors (two of each phone) with this symptom. They did not have any state class but appeared in this list.
After some googling it seems a few other people also recently had this same problem and the suggestion was to clear the app cache and uninstall it, also uninstall the integration and then reinstall everything again. I was not willing to do this because this reminds me of 20 year old Microsoft bug fixing strategy. So i just used the reload command of the integration (because I remember this has also in the past helped force updating changed names and properties of other integrations).
Half an hour after I dd this the state_class=measurement appeared in the two sensors for my phone and another hour later the two sensors of my wife’s phone also had this new state_class property. They all show up in statistics now without errors.
I too seem to have this problem, also accidentally stumbled across it. Almost all of my water leak sensors and any sensor that shows temperatures (water leak, door/motion sensors, etc) suddenly have the ‘fix issue’. I have not touched any of these sensors in months, and have not added a thing to HA except upgrades for the past several months. No idea. This is all on a Windows PC, and HA is running on a Odroid N2+ with no problems for months as well. I’m lost. I’m hesitant to click the fix issue as it asks if I want to remove it, and of course I don’t.
Never mind, I think i goofed. Apparently renaming sensors requires younger heads than mine!
Thanks for looking though. I’ll muddle through this, as I’m not sure what happened otherwise. Maybe an old named sensor, who knows.
*Edit
Yes definitely, either renaming sensors, or changing/upgrading sensors, I did remove them from Zigbee properly, just that the recorder kept track once the name appeared, even if it was removed.
I just went through the painstaking way of looking at a battery level or temp sensor, checking the current dashboard, going in and checking the code name, then flipping back to the dev tools stats page, where many were renamed, as I stayed close to naming conventions, I just add a few letters telling where the sensor is… hence, MB_L stands for master bathroom Left sink, in the case of the above water sensor.
Again sorry for the confusion, maybe someone will double check themselves and be able to fix the problem based on my current experience with this.
Thanks again.