2024-01-07 14:54:09.884 ERROR (MainThread) [homeassistant.components.homeassistant] The service homeassistant.turn_on cannot be called without a target
2024-01-07 14:54:36.143 ERROR (MainThread) [homeassistant.components.homeassistant] The service homeassistant.turn_off cannot be called without a target
2024-01-07 15:21:27.968 ERROR (MainThread) [homeassistant.components.homeassistant] The service homeassistant.turn_off cannot be called without a target
but I cannot understand what they are related to.
Is there any way to diagnose?
Which is the service that gives an error?
Search your automations and scripts for: “homeassistant.turn”.
You have forgotten to supply an entity_id in at least two places where you have used these services. Or if using templates the templates are not resolving correctly to an entity_id for these services.
I’ve checked and it was not manually triggered.
I still have several of them:
2024-12-29 17:48:21.336 ERROR (MainThread) [homeassistant.components.homeassistant] The service homeassistant.turn_on cannot be called without a target
2024-12-29 17:48:21.348 ERROR (MainThread) [homeassistant.components.homeassistant] The service homeassistant.turn_on cannot be called without a target
2024-12-29 17:48:21.349 ERROR (MainThread) [homeassistant.components.homeassistant] The service homeassistant.turn_off cannot be called without a target
2024-12-29 17:48:21.356 ERROR (MainThread) [homeassistant.components.homeassistant] The service homeassistant.turn_off cannot be called without a target
But how can I understand it better?
If the automation is declared on the web interface I cannot search them.
I need to know what was happening when this was triggered
I just got done fighting a similar problem. And, like you, I searched automations.yaml and scripts.yaml and couldn’t find “home_assistant.turn_on”.
So, today for the zillionth time I looked at the logbook to see what was going on at the times that the home_assistant.log reported the error. And one of the things was a fan being turned off with generic turn off (which I don’t use in my automations).
And it finally occurred to me that it was a blueprint for turning on an exhaust fan when my bathroom humidity gets too high. I was using version 1.4 of the blueprint and it’s up to version 2.6. So I redownloaded that blueprint and hopefully the errors will go away.
wow!!! for sure this is an area that should get an evolution.
I’m using only a blueprint to switch on/off a light with multiple switches.
All the rest are automations I wrote in the automation menu