I have automation set up on my driveway lights to come on when motion is detected on a ring cam after sun set.
It all works fine apart from the fact that at sun set the light just come on. I either have to turn them off through the front end or motion is triggered and the three minute timer finished and they turn off. Happens every day regular as clockwork!
Are you 100% sure it’s that automation that triggers your lights?
Next time it happens, you can go to your automations and sort by “last triggered” to see if this specific automation was ran.
Sun set
17:12:58 - 6 minutes ago
[Stable Light](http://192.168.1.114:8123/logbook#) turned on by Home Assistant Cloud
17:11:04 - 8 minutes ago
[Driveway Lamp 3](http://192.168.1.114:8123/logbook#) turned on by Home Assistant Cloud
17:11:03 - 8 minutes ago
[Driveway Lamp 2](http://192.168.1.114:8123/logbook#) turned on by Home Assistant Cloud
17:11:03 - 8 minutes ago
[Driveway Lamp 4](http://192.168.1.114:8123/logbook#) turned on by Home Assistant Cloud
17:11:03 - 8 minutes ago
[Driveway Lamp 1](http://192.168.1.114:8123/logbook#) turned on by Home Assistant Cloud
17:11:02 - 8 minutes ago
[Driveway Lamp 6](http://192.168.1.114:8123/logbook#) turned on by Home Assistant Cloud
17:11:02 - 8 minutes ago
[Gate light](http://192.168.1.114:8123/logbook#) turned on by Home Assistant Cloud
17:11:01 - 8 minutes ago
[Amazon Alexa](http://192.168.1.114:8123/logbook#) sent command Alexa.PowerController/TurnOn for Stable Light by Home Assistant Cloud
17:11:01 - 8 minutes ago
[Amazon Alexa](http://192.168.1.114:8123/logbook#) sent command Alexa.PowerController/TurnOn for Driveway Lamp 3 by Home Assistant Cloud
17:11:01 - 8 minutes ago
[Amazon Alexa](http://192.168.1.114:8123/logbook#) sent command Alexa.PowerController/TurnOn for Driveway Lamp 2 by Home Assistant Cloud
17:11:01 - 8 minutes ago
[Amazon Alexa](http://192.168.1.114:8123/logbook#) sent command Alexa.PowerController/TurnOn for Gate light by Home Assistant Cloud
17:11:01 - 8 minutes ago
[Amazon Alexa](http://192.168.1.114:8123/logbook#) sent command Alexa.PowerController/TurnOn for Driveway Lamp 4 by Home Assistant Cloud
17:11:00 - 8 minutes ago
[Amazon Alexa](http://192.168.1.114:8123/logbook#) sent command Alexa.PowerController/TurnOn for Driveway Lamp 1 by Home Assistant Cloud
17:11:00 - 8 minutes ago
[Amazon Alexa](http://192.168.1.114:8123/logbook#) sent command Alexa.PowerController/TurnOn for Driveway Lamp 6 by Home Assistant Cloud
17:11:00 - 8 minutes ago
So it looks like the command is being issued by Alexa.PowerController a couple of minutes before sun set.
Checked on the Alexa app and it seems I had left a test routine running.