Combining data from wview archive with recent data from weewx

55 views
Skip to first unread message

richard maliszewski

unread,
Apr 9, 2021, 4:25:07 PM4/9/21
to weewx-user
WeeWX and I are getting along well.  We had a wview installation that had accumulated 7+ years of readings from a TE923W.  The recent WeeWX data is only a week or two.  I have done the DB shuflle and WeeWX is creating summary data and such for the pile of wview data.

It's not a huge loss if it's not doable, but once that settles, is there any reasonable way to import the recent WeeWX data into the resulting weewx.sdb?  Per the guide, I kept that as weewx.sdb.bak, so it's still available.

--Richard

richard maliszewski

unread,
Apr 9, 2021, 5:02:27 PM4/9/21
to weewx-user
Probably not worth sweating, as Weewx seems to have stitched everything back together except earlier today...and that's fine.  However, after switching to the wview SDB file, I am seeing an error every cycle from WeeWX in the log:

Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine: Caught unrecoverable exception in generator 'weewx.imagegenerator.ImageGenerator'
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****  pm2_5
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****  Traceback (most recent call last):
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weewx/reportengine.py", line 196, in run
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****      obj.start()
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weewx/reportengine.py", line 281, in start
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****      self.run()
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weewx/imagegenerator.py", line 41, in run
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****      self.genImages(self.gen_ts)
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weewx/imagegenerator.py", line 180, in genImages
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****      aggregate_interval=aggregate_interval)
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weewx/xtypes.py", line 91, in get_series
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****      raise weewx.UnknownType(obs_type)
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****  UnknownType: pm2_5
Apr  9 13:50:24 minix weewx[6296] ERROR weewx.reportengine:         ****  Generator terminated

This is new behavior as of the switch to the wview archive.  Nothing else has been changed.  It looks like things are mostly trundling along.  Any idea why this new error?  I am suspicious that the GW1000 extension install did something to the DB that my switch to the wview DB has now undone.  Digging.

--Richard

vince

unread,
Apr 9, 2021, 5:12:21 PM4/9/21
to weewx-user
Not a great problem description for us to work on, but my guess is that your old db is the old wview-compatible schema and the new software expects the newer wview-extended schema.  

Easiest way to check your db is see how many tables are in your db:
      echo ".schema" | sqlite3 /home/weewx/archive/weewx.sdb | wc -l

If you see 114 lines there, you have the extended schema.  I think the number is 40 or so with the old wview-compatible schema.

Converting from old to new/bigger schema is documented in the wiki at https://github.com/weewx/weewx/wiki/Switching-to-the-new-wview_extended-schema

Tom Keffer

unread,
Apr 9, 2021, 6:08:33 PM4/9/21
to weewx-user
Alternatively, V4.5.1 allows you to add new data types one-by-one. See the section Adding a new type to an existing database in the Customizing Guide.

--
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 weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/723afe71-8b4c-43a4-913e-dcb5f6a0c91cn%40googlegroups.com.

richard maliszewski

unread,
Apr 9, 2021, 6:14:01 PM4/9/21
to weewx-user
Converting the wview DB to the extended schema made everything happy.  Took a while.

--Richard

Reply all
Reply to author
Forward
0 new messages