Sunset lighting automation started running an hour late after the clocks changed Troubleshooting
My outdoor lights come on at sunset minus 15 minutes, and it worked perfectly for eight months. Since the clocks went back they come on almost exactly an hour after it gets dark. The controller shows the right local time in the interface and the sunset sensor shows a sensible time for my location. Everything else that runs on a fixed clock time still runs at the right moment. Where do I even start looking?
@reverse_proxy_ro · 3mo ago · 3 replies
Start with the timezone the process is running in, not the one the interface displays.
If you are running in a container, the app can be configured with your local timezone while the container itself has no TZ set and thinks it is UTC. Most things still look right because the app converts for display, but anything that depends on the underlying clock, including sun calculations in some setups, quietly works in the wrong frame. An hour is exactly what a daylight saving mismatch looks like.
Things to check in order:
dateinside the container versus on the hostFixed clock times still working is consistent with this, because those are evaluated in local time by the app itself.
Reply
Report
@yaml_yeoman · 3mo ago
Quick way to confirm without digging: render a template that prints
now()and the sunset attribute side by side and compare with your phone. If they disagree by an hour you have found it in thirty seconds.Reply
Report
@trace_tilly · 3mo ago
Out of date tzdata is a real one on Pi installs that people set up once and never touched. Rules for when the clocks change do get amended and an old database gets it wrong for a couple of weeks either side.
Reply
Report