AmoebeLabs / swiss-army-knife-card

The versatile custom Swiss Army Knife card for Home Assistant allows you to create your unique visualization using several graphical tools, styling options and animations.
236 stars 20 forks source link

"Cannot read properties of undefined (reading 'state')" #169

Closed PeterGrace closed 1 year ago

PeterGrace commented 2 years ago

Bug report notice

Bug description

As mentioned in #161, after fixing the templates issue I am now stuck with the below error message, "Cannot read properties of undefined (reading 'state').

The same behavior is shown in the Android home assistant application.

To Reproduce

Steps to reproduce the behavior:

  1. Attempt to load any VSAK view, regardless of template or not.
  2. See error

Expected behavior

Proper rendering of information from sensor states in the visualization

Screenshots

image

Desktop browser (please complete the following information):

Companion App on Smartphone/Tablet (please complete the following information):

github-actions[bot] commented 2 years ago

Thank you for creating your first issue for the Swiss Army Knife custom card!

Symbiot78 commented 1 year ago

@PeterGrace - I had the same issue. Reason was that the entity did not exist.

PeterGrace commented 1 year ago

I can confirm that this error occurs if one or more sensors in your config don't exist. In my case, I had a linkquality sensor configured which was disabled and as a result it caused the whole template to fail rendering. Thanks @Symbiot78 !!!