core
core copied to clipboard
Compensation integration not supported in statistics graph
The problem
I added a compensation to adjust the temperature of one of my sensors:
compensation:
temperature_balcony:
source: "sensor.0xa4c13867c353a9ea_temperature"
data_points:
- [0.5, 0]
- [10.5, 10]
unit_of_measurement: '°C'
unique_id: compensation_0xa4c13867c353a9ea_temperature_balcony
I wanted to add it to a statistics graph, but couldn't. The dropdown tells me to show the developers this URL: https://developers.home-assistant.io/docs/core/entity/sensor/#long-term-statistics
What version of Home Assistant Core has the issue?
core-2023.7.1
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant Container
Integration causing the issue
Compensation
Link to integration documentation on our website
https://www.home-assistant.io/integrations/compensation
Diagnostics information
I can share them, but not sure that's useful in this case.
Example YAML snippet
No response
Anything in the logs that might be useful for us?
No response
Additional information
No response
Hey there @petro31, mind taking a look at this issue as it has been labeled with an integration (compensation
) you are listed as a code owner for? Thanks!
Code owner commands
Code owners of compensation
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 compensation
Removes the current integration label and assignees on the issue, add the integration domain after the command.
(message by CodeOwnersMention)
compensation documentation compensation source (message by IssueLinks)
Same problem here. A workaround is maybe to create a template sensor with "state_class: measurement" that just represents the compensation value. It's just a hassle having to do that for every compensated sensor.
Yeah, I'm now using a template sensor instead. It would be nice to use Compensation for this instead, as that's what it's meant to be used for (it's easy to make mistakes with templates).
The integration isn't designed to work with it yet. You can add state_class: measurement and a device_class via customize.yaml to get it to work with statistics.
ah, that worked, thank you!
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.
I have no reason to believe the bug went away.
(Also, please don't use stalebot, it's highly discouraging to contributors).
- it's not a bug. What you're asking for is a feature request.
- the stale bot is automatic, this will happen again until I add the new functionality.
I just filed a dupe of this: https://github.com/home-assistant/core/issues/103785
Compensation sensor should really be smart enough to inherit the device class and state class of the parent sensor. That would be the best fix.
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.
Somehow this got corrected in January 2024. This can be closed.
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.