Changing state of "Times of the Day" binary sensor while the system is off

I hope to be in the right category.

I have a problem with a " Times of the Day" binary sensor, and I’m not sure if I’ve done something wrong in the configuration, but I don’t see any other options, or it might be a minor bug.

The issue occurs when the sensor changes its state while Homeassistant is off.
Upon the next Homeassistant startup, the sensor’s state is displayed correctly, but the change is not recorded, and the automations that are triggered by that event do not activate.
I can resolve this by adding a trigger to my automations that checks the state every time Homeassistant starts, but I would like to understand if this is a bug to report or if it’s intentionally designed this way.

Screenshot 2023-08-05 101253

The example sequence is as follows:
11:00 PM Homeassistant turning off
5:30 AM change of sensor state
6:00 AM Homeassistant starting up

I hope I have explained myself well.

triggers only occur on a change to the entity state.

if the state is already in that condition when HA starts there is nothing to register the state change so the trigger won’t fire.

So it’s not a bug but just inherent in the way the automation system works.

Okay, thank you. So, I’ll set the trigger to activate upon startup if this is the correct operation.