swiss-army-knife-card
swiss-army-knife-card copied to clipboard
"Cannot read properties of undefined (reading 'state')"
Bug report notice
- [ ] Yes, I'm sure that it is not a configuration mistake (Maybe? How do I know what I don't know?)
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:
- Attempt to load any VSAK view, regardless of template or not.
- See error
Expected behavior
Proper rendering of information from sensor states in the visualization
Screenshots
Desktop browser (please complete the following information):
- OS: Windows 10
- Browser: Chrome
- Version: 106.0.5249.91
Companion App on Smartphone/Tablet (please complete the following information):
- Device: Samsung Galaxy S21 Ultra
- OS: Android
Thank you for creating your first issue for the Swiss Army Knife custom card!
@PeterGrace - I had the same issue. Reason was that the entity did not exist.
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 !!!