i store the ha version in a variable, and can compare with new version to decided show this badges or not in filter . but now I only change the value manually.
I don’t know the answer of your question, but if you just want to show if there is a newer version of your local one, there is a specific updater badge for this.
Back to my original question, if you intent to show a badge if there is a new version of home assistant, you don’t have to worry about variables etc, just use updater badge which reads your local version and checks against latest one.