OpenSprinkler › Forums › Hardware Questions › OpenSprinkler Pi (OSPi) › All valves engaged on boot › Re: Re: All valves engaged on boot
Maybe wrap the log write within a try? Or anything interacting with the SD card?
While that would technically solve the issue, it’s more hiding a symptom rather than fixing the cause. Really, empty zone names should be fine, as zone names are just convenience for humans. The control system shouldn’t care about the name, and just report it as is, empty or not. However, log files missing entries because the zone name happens to be empty is not so good.
I’m not saying the logging functionality shouldn’t be protected by a try/catch. Obviously, having the control system barf due to an issue with logging isn’t good. I’m just afraid that try/catch can make a programmer lazy 🙂