Using the tool sqlite3 (you may have to install), see how many zero interval values are in your database:
Adjust path as necessary, but this path should be close: $ *sqlite3 /home/pi/cleusb/weewx/archive/weewx.sdb* sqlite> *select dateTime, datetime(dateTime,'unixepoch','localtime'), interval from archive where interval<=0;* If there is only one or two of them, I'd just delete them, then try rebuilding the daily summaries again: sqlite> *delete from archive where interval<=0;* -tk -tk On Mon, Sep 30, 2019 at 8:58 AM Cyril D <[email protected]> wrote: > Hello, > > Following a bug on my system that sends incorrect values to weewx, I had > to delete records from the archive database. > Then I run: > > wee_database weewx.conf --drop-daily > > Followed by > wee_database weewx.conf --rebuild-daily > > With this latest command I get this error: > ./bin/wee_database weewx.conf --rebuild-daily > Using configuration file weewx.conf > Using database binding 'wx_binding', which is bound to database > 'archive_mysql' > All daily summaries will be rebuilt. > Proceed (y/n)? y > Rebuilding daily summaries in database 'weewx' ... > Traceback (most recent call last):e: 2017-04-11 14:41:06 CEST (1491914466) > File "./bin/wee_database", line 794, in <module> > main() > File "./bin/wee_database", line 153, in main > rebuildDaily(config_dict, db_binding, options) > File "./bin/wee_database", line 263, in rebuildDaily > trans_days=20) > File "/home/pi/cleusb/weewx/bin/weewx/manager.py", line 1469, in > backfill_day_summary > weight = self._calc_weight(rec) > File "/home/pi/cleusb/weewx/bin/weewx/manager.py", line 1582, in > _calc_weight > raise ValueError("Non-positive value for record field 'interval': %s" % > (record['interval'], )) > ValueError: Non-positive value for record field 'interval': 0 > > What should I do? > > -- > You received this message because you are subscribed to the Google Groups > "weewx-user" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/weewx-user/1edda18d-b9df-4ee5-9175-f43a61ef4a1b%40googlegroups.com > <https://groups.google.com/d/msgid/weewx-user/1edda18d-b9df-4ee5-9175-f43a61ef4a1b%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "weewx-user" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/CAPq0zEDiCmp4C6VAQ8LDhN6TzKkEGySk8VWZfEA8EmR2tO%3Dpog%40mail.gmail.com.
