Having an issue getting a dynamic max value entry into a lovelace card. I want to have a dashboard that gets cast to my Google Hub when I start a cooking session an any of my Meater probes. One card I would like to see is a dynamic gauge card where the current value is the current probe internal temperature and the max value of the gauge is the target temperature. Cant seem to get the template syntax correct. Here is what I have:
type: custom:card-templater
card:
type: gauge
show_header_toggle: false
entity: sensor.meater_probe_internal_2
min: 0
max: "{{states('sensor.meater_probe_target_2')|int}}"
The result is as if the max value is set to zero. No bar is displayed. If I hard-code a max value, it works as expected. Running the template through the debugger returns the expected 122. What am I doing wrong?