Unavailable Template Sensor - Temperature Difference

I’m trying to create a template sensor that tracks the temperature difference between two other entities.

I have the following template, which works and updates the value of the sensor.

However, the template sensor entity itself says that it is unavailable for some reason.

I cant seem to see anything in the logs for why this is the case.

Any info someone can provide would be amazing.

choose a device class (temperature) and state class (measurement)