custom-components / weatheralerts

A sensor that gives you weather alerts from alerts.weather.gov.
MIT License
123 stars 15 forks source link

Invalid config for 'homeassistant' at packages/weatheralerts_1.yaml, line 2643 #79

Open Zouljiin opened 5 months ago

Zouljiin commented 5 months ago

Version of the custom_component performing initial setup of latest version. pulled yaml text from raw. the sensor does show up in my entities list with the correct county name and it was renamed weatheralerts_1 as per instructions. im getting the below error when tryin to reboot after pasting the yaml

Describe the bug Configuration errors Invalid config for 'homeassistant' at packages/weatheralerts_1.yaml, line 2643: expected a dictionary for dictionary value 'packages->automation', got [{'alias': 'Weather Alert UI Notification - 1', 'initial_state': True, 'trigger': [{'platform': 'state', 'entity_id': 'sensor.weatheralerts_1_alert_1_last_changed'}, {'platform': 'homeassistant', 'event': 'start'}], 'condition': [{'condition': 'and', 'conditions': [{'condition': 'template', 'value_template': "{{ states('sensor.weatheralerts_1_alerts_are_active') == 'Yes' }}"}, {'condition': 'template', 'value_template': "{{ (as_timestamp(now()) - as_timestamp(stateattr('sensor.weatheralerts... Invalid config for 'homeassistant' at packages/weatheralerts_1.yaml, line 49: expected a dictionary for dictionary value 'packages->sensor', got [{'platform': 'template', 'sensors': {'weatheralerts_1_active_alerts': {'friendly_name': 'Weather Alerts', 'unit_of_measurement': 'Alerts', 'icon_template': 'mdi:alert-rhombus', 'value_template': "{% set alerts_total = namespace(count=0) %} {% if (state_attr('sensor.weatheralerts_1', 'alerts')) %}\n {% for alert in state_attr('sensor.weatheralerts_1', 'alerts') %}\n {% if as_timestamp(alert['endsExpires']) - as_timestamp(now()) > 0 %}\n {% set alerts_total.count = alerts_total.count ...

IIAIronWolf commented 2 months ago

I don't think this person is maintaining this anymore. Have you tried deleting and reinstalling it?

Zouljiin commented 2 months ago

I have not. I haven't even messed with it since posting this.