Closed bakerkj closed 7 years ago
Just after midnight, before the archive has been processed rtgdthread produces these errors:
Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: Traceback (most recent call last): Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: File "/usr/share/weewx/user/rtgd.py", line 926, in process_packet Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: data = self.calculate(cached_packet) Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: File "/usr/share/weewx/user/rtgd.py", line 1560, in calculate Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: self.wind_group).value/self.day_stats['wind'].count Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: ZeroDivisionError: float division by zero
I believe this is because self.day_stats['wind'].count is zero because there is no wind data between midnight and 5 minutes after midnight.
This was fixed at commit 92a4a777ba635088378c0a643535b0efc81c7f66 which was to be released as v0.2.12 but for some reason I did not release v0.2.12. v0.2.13 will include the fix.
Just after midnight, before the archive has been processed rtgdthread produces these errors:
Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: Traceback (most recent call last): Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: File "/usr/share/weewx/user/rtgd.py", line 926, in process_packet Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: data = self.calculate(cached_packet) Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: File "/usr/share/weewx/user/rtgd.py", line 1560, in calculate Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: self.wind_group).value/self.day_stats['wind'].count Apr 25 00:00:16 HOSTNME weewx[29890]: rtgdthread: ZeroDivisionError: float division by zero
I believe this is because self.day_stats['wind'].count is zero because there is no wind data between midnight and 5 minutes after midnight.