Open DanielHabenicht opened 5 months ago
I assume it's always been the intention for this card to hide diagnostic sensors, as they are sort of intended as not the "primary" sensors of interest for an area, but just secondary information. Admittedly its a grey area.
I've heard that there are some plans in the work for more configuration options for areas that might allow you to choose what sensors are relevant for your area, but I think that's a long term project.
If you really want this sensor shown, I guess the best way that could be achieved right now is just to make a new template sensor for it, and then it would not be tagged as diagnostic.
Get it, but what's the benefit of not making them availabe here? One has to set which one to display anway.
I would rather contribute that, than adding a template sensor for each of my battery sensors.
I guess it's a question of if having those secondary sensors displayed would pollute the card or otherwise mess up the information that most people want to be shown.
I guess I think it's probably mostly an issue for the sensors which do averaging (less so for binary sensors), where having a diagnostic sensor "averaged" with the primary sensor would mess up the result, like maybe where a device has a diagnostic temperature sensor that you don't want or expect to be averaged with a primary room temperature sensor.
But specifically for the binary sensors, maybe an argument could be made to include the diagnostic ones as well.
If you're interested in contributing, feel free to make a pull request for the behavior you think would be correct, and you can get maintainer feedback to see if it's something they would accept. I was just pointing out why I believed it was designed this way.
Appreciate your knowledge, thats why I added an issue instead of directly opening a PR.
Yes, if contributing I would only include the binary sensors, but as I read it the current "alert_classes" only accept binary sensors anyway. I wouldn't change the "sensor_classes"
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.
Hi. I agree that the Information of a battery state is usually a secondary information - and per device Level, IT IS correct to See them as Diagnostic.
But - even since it is only a secondary information - and nothing that will be permanently visible to me in the Dashboard, it would make Sense in my eyes to Show them as a possible Alarm in the area Card - if the battery of a device will be reported as empty.
OK. True, i still have to Check, which device would report the empty battery... But it would allow me to immediately Check the window Sensors or Thermostat in that room / area before i notice this, due to an bin updated / Not available Sensor somewhere in the House
Checklist
Describe the issue you are experiencing
When specifying "battery" in the![image](https://github.com/home-assistant/frontend/assets/13590797/4021488e-897c-4e14-9fe3-006e8973ef9b)
alert_classes
of an area card with a known battery warning (meaning the binary_sensor of the battery entity is on):No alert is shown, as it would be with an open window.
Describe the behavior you expected
I would expect a battery symbol to be shown, as it would be the case for an open window:![image](https://github.com/home-assistant/frontend/assets/13590797/a36636f3-38f7-4fd9-bd19-6a22c4d87303)
Steps to reproduce the issue
binary_sensor
) and add it to an area 'X'.binary_sensor
to on.What version of Home Assistant Core has the issue?
core-2024.2.5
What was the last working version of Home Assistant Core?
No response
In which browser are you experiencing the issue with?
Google Chrome Version 122.0.6261.69 (Official Build) (64-bit)
Which operating system are you using to run this browser?
Windows 11
State of relevant entities
Problem-relevant frontend configuration
Javascript errors shown in your browser console/inspector
Additional information
Seems like any sensor with a class is filtered from being displayed in the card: https://github.com/home-assistant/frontend/blob/94e70f81edb58bb8ad270a20d31cf9880be677e3/src/panels/lovelace/cards/hui-area-card.ts#L130-L137
As Diagnostic Devices already have
entity_category: "diagnostic"
set.