Check for sane value of archive_delay. Remove it from weewx.conf

This commit is contained in:
Tom Keffer
2016-10-16 12:12:23 -07:00
parent 297005c485
commit 7cb6db4211
2 changed files with 3 additions and 4 deletions

View File

@@ -476,6 +476,9 @@ class StdArchive(StdService):
if self.archive_delay <= 0:
raise weewx.ViolatedPrecondition("Archive delay (%.1f) must be greater than zero." %
(self.archive_delay,))
if self.archive_delay >= self.archive_interval / 2:
syslog.syslog(syslog.LOG_WARNING, "engine: Archive delay (%d) is unusually long" %
(self.archive_delay,))
syslog.syslog(syslog.LOG_DEBUG, "engine: Use LOOP data in hi/low calculations: %d" %
(self.loop_hilo,))

View File

@@ -281,10 +281,6 @@ version = 3.6.1
# will be downloaded from the station. Otherwise, specify it (in seconds).
archive_interval = 300
# How long to wait (in seconds) before processing new archive data. Must
# be greater than zero.
archive_delay = 15
# If possible, new archive records are downloaded from the station
# hardware. If the hardware does not support this, then new archive
# records will be generated in software.