Open queimadus opened 4 years ago
I get the following error in my frontend until I reload at least once.
It also shows this on my mobile device.
r.setConfig is not a function entity: lock.front_door name: Front Door secondary_info: >- <b style="[[ if(lock.front_door.state == "locked","color:green","color:red") ]]">[[ {entity}.attributes.lock_status ]]</b> type: 'custom:secondaryinfo-entity-row'
I'm wondering if this is the same issue or not...
Same here!
r.setConfig is not a function bla bla bla...
Takes a few seconds to get the value.
To be fair it's a tricky one because the secondary_info entity it's a template
sensor getting his state from another history_stat
sensor. Fair enough that takes a sec to update but the real problem for me it's the error! It's unbearable. A giant red square in the middle of you home...
Card
entities:
- entity: climate.furnace
hold_action:
action: more-info
secondary_info: 'Active for [[ sensor.furnace_on_time ]] '
tap_action:
action: navigate
navigation_path: /lovelace/furnace
type: 'custom:secondaryinfo-entity-row'
state_color: true
type: entities
Sensors
- platform: history_stats
name: Furnace ON time raw
entity_id: sensor.furnace_operation_mode
state: 'Heating'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
duration:
hours: 24
- platform: template
sensors:
furnace_on_time:
friendly_name: Furnace ON time
value_template: >-
{{ state_attr('sensor.furnace_on_time_raw', 'value') }}
Happy to share more if can help!
Any idea what's the issue here? The error Cannot read property 'shadowRoot' of null
is still here and in case it occurs the card stays empty (not just missing secondary info). Sometimes it takes a couple of reloads until it's correctly displayed.
Have you updated card-tools to latest version (11) ?
Yes, I'm currently running the latest version 11 (reported as 2.1.2 in the console). The error did also occur with the previous version. Sometimes the result of this._wrappedElement.shadowRoot.querySelector("hui-generic-entity-row")
is null and the chained usage of shadowRoot.querySelector(".secondary")
fails. I also tried to dig into this by myself, but without luck as I'm not a JS developer.
I confirm....card is working, but I have this error on Chrome console...
and details...
This seems to coincide with the home assistant 0.110 update (currently on 0.110.4). It takes a few ticks to
_updateElement
for the information to update.Error details: