Like francisp explained, that’s in the example posted by Mariusthvdb. When I posted a revised version of his example, I purposely excluded the YAML anchor to simplify it and avoid confusion.
A YAML anchor let’s you duplicate a section of YAML elsewhere simply by referring to it by name. I provided an example for someone else in this thread.
The complaint comes from VS Code Config Helper. It works with VS Code to identify potential errors in your YAML code. It probably hasn’t been updated yet so it falsely identifies those two options as being “not allowed”.
still nothing… (Had to put a close “)” on that to make it work)… I’ve even tried hardcoding the date in the right format but never got HA to recognize it.
I know this topic is old and you may know why this happened now but for anyone arriving here as I did I believe it’s because of the state_class being set to measurement in your case.
I used the state_class: total and the value I put in to last_reset_value_template is then populated.
But TOTAL defeats the purpose of measurement. TOTAL means acumulated amount, while measurement mean sin current time. Lets say energy - some device gives you how many watts it’s using right now, TOTAL wont be good in this case. It’s DUMB to require reset with measurement. What reset? it resets everytime device is off