question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Attribute defined entity cannot be added to energy dashboard

See original GitHub issue

I have my bathroom floor heating configured as follows:

- platform: powercalc
  entity_id: climate.bathroom_thermostat
  fixed:
    states_power:
      heat|OFF: 0
      heat|ON: 400

The power and energy entities are correctly created and reflect the state of the heating:

Power:

sensor.bathroom_thermostat_power

400.0

source_entity: climate.bathroom_thermostat
source_domain: climate
unit_of_measurement: W
friendly_name: Bathroom Floor power
device_class: power

Energy:

sensor.bathroom_thermostat_energy

0.0710

state_class: measurement
source: sensor.bathroom_thermostat_power
source_entity: climate.bathroom_thermostat
source_domain: climate
unit_of_measurement: kWh
friendly_name: Bathroom Floor energy
icon: mdi:lightning-bolt
device_class: energy
last_reset: 1970-01-01T00:00:00+00:00

however when I try to add the the energy entity as as individual device to the energy dashboard it’s not listed and cannot be added, Bathroom Thermostat is missing:

image

I do have 20+ other powercalc entities (light/switch) defined, all those show up as expected so the only difference I see in this one is that it’s defined as an attribute.

For example this entity shows up correctly (as you can see above)

- platform: powercalc
  entity_id: light.bathroom_mirror
  linear:
    min_power: 0
    max_power: 80
  name: Bathroom Mirror Light Power

for completeness this is what the attributes of the related energy entity look like (I don’t see anything extra not defined in the entity not working correctly)

state_class: measurement
source: sensor.bathroom_mirror_light_power
source_entity: light.bathroom_mirror
source_domain: light
unit_of_measurement: kWh
friendly_name: Bathroom Mirror Light energy
icon: mdi:lightning-bolt
device_class: energy
last_reset: 1970-01-01T00:00:00+00:00

Let me know if you need any other details to troubleshoot this (or whether this is more of an HA issue than Powercalc)

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:10 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
OmgImAlexiscommented, Sep 6, 2021

For what it’s worth my own issue was resolved once I updated to the 2021.9.3 .2 and below seems to have this issue at least for me.

@Plawasan have you updated yet?

1reaction
bramstrokercommented, Sep 6, 2021

@Plawasan very strange behaviour. I have no clue. Seems like a bug in energy dashboard, especially since you are also able to reproduce missing entity by defining integration sensor yourself. Not able to reproduce this issue myself (yet). I would suggest you post this on HA forum, or home assistant core issue tracker. Hopefully someone of HA community knows cause and solution.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Sensor can`t be added to energy dashboard #71334 - GitHub
The problem The Plugin works. But i cannot add the sensor to the energy dashboard. tried some ideas from the net regarding some ......
Read more >
Can't add entity to energy dashboard - Configuration
Hello! I am having some trouble with the energy dashboard. I own three identical plugs with a built-in powermeter. I can add two...
Read more >
Take control with your Online Energy Dashboard - FPL
Your personalized Online Energy Dashboard gives you the power to see how much energy you're using and discover new ways to save on...
Read more >
Blackbaud The Raiser's Edge Configuration & Security Guide
Any tables or table entries you define cannot be deleted if they are used on any records in the program. “Add Entries and...
Read more >
Modeling Data in the Organization
Define terms; Understand importance of data modeling; Write good names and definitions for entities, relationships, and attributes; Distinguish unary, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found