-
-
Notifications
You must be signed in to change notification settings - Fork 136
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Template variable warning: 'value_json' is undefined #1301
Comments
what are the arguments given to ebusd? maybe |
2024-07-16 12:49:11.007 [main notice] ebusd 23.2.p20230716 started with auto scan on device: 192.168.178.68:9999, enhanced |
seems to be some issue with HA not providing the message value as "value_json" variable. did you change the mqtt-hassio.cfg file? or somehow disable mqtt json support in HA? |
if this is still an issue, then please post here the value actually sent to HA in the MQTT integration for the global/updatecheck topic |
again the question if --mqttjson was passed to ebusd as I doubt that |
Yes, ebusd runs with the --mqttjson option set |
and was the updatecheck topic last pushed to recently, i.e. with the mqttjson set? |
I'm running 20231015 on the adapter - would updating it help ? |
I don't think so. it anyway depends on when the message was last received, so please just check in HA when the last message was received. i suspect that to be too old |
You are right: the message is not appearing anymore. |
Description
2024-07-10 20:42:43.773 WARNING (MainThread) [homeassistant.helpers.template] Template variable warning: 'value_json' is undefined when rendering '{% set my_new = value_json|truncate(255)|regex_replace(find='^[^,]|, device firmware |,.| available',replace='') %}{% set my_cur = 'old' %}{% if my_new == '' %}{% set my_new = 'current' %}{% set my_cur = 'current' %}{% endif %}{{ {'installed_version':my_cur,'latest_version':my_new,'entity_picture':'https://adapter.ebusd.eu/favicon.ico','release_url':'https://adapter.ebusd.eu/firmware/ChangeLog'} | tojson }}'
2024-07-10 20:42:43.775 WARNING (MainThread) [homeassistant.helpers.template] Template variable warning: 'value_json' is undefined when rendering '{% set my_new = value_json|truncate(255)|regex_replace(find=',.*| available|revision v|version v|OK',replace='') %}{% if my_new == '' %}{% set my_new = '23.2' %}{% endif %}{{ {'installed_version':'23.2','latest_version':my_new,'entity_picture':'https://ebusd.eu/logo-32x32.png','release_url':'https://github.com/john30/ebusd/releases/latest'} | tojson }}'
Actual behavior
none
Expected behavior
startup error
ebusd version
23.2
ebusd arguments
none
Operating system
Debian 12 (Bookworm) / Ubuntu 22-23 / Raspberry Pi OS 12 (including lite)
CPU architecture
x64
Dockerized
None
Hardware interface
Adapter Shield v5 via Ethernet
Related integration
MQTT Home Assistant via mqtt-hassio.cfg
Logs
none
The text was updated successfully, but these errors were encountered: