Your StdReport and DatabaseTypes sections use relative pathnames based on 
WEEWX_ROOT being expected.

https://www.weewx.com/docs/5.2/upgrade/?h=weewx_root#weewx_root-is-now-relative-to-the-configuration-file
 has 
a non-breaking change in that area.  Guessing a 5.2 upgrade might solve 
your issue since WEEWX_ROOT is optional in 5.2 now.  I left it in my .conf 
files anyway, FWIW.

On Monday, December 22, 2025 at 11:00:51 AM UTC-8 Greg Troxel wrote:

> My setup:
>
> NetBSD 9 earmv7hf-el (RPI3)
> Vantage Pro2 serial logger
>
> weewx 5.1.0 (yes, I know that's old; trying to understand/minimize
> before upgrading)
>
> Modified Standard skin (remove some things, rearrange html, but
> nothing really serious)
>
> rsync of generated html to another machine
>
> MQTT extension, archive only, json dictionary, read by Home Assistant
>
> and in particular
>
> weewx installed in the system python directory as a package
>
> $HOME/weewx-data is my root directory, and contains weewx.conf and skins
>
> $HOME/weewx-data/archive/weewx.sdb is my (sqlite3) archive file
>
> weewx invoked by a script that waits for NTP sync, and then
> cd /home/gdt/weewx-data
> weewxd-3.12 weewx.conf
>
> For a long time I have had in my weewx.conf
>
> # \todo Why is this not in the example? Why is it needed?
> WEEWX_ROOT=/home/gdt/weewx-data
>
> and everything works fine.
>
> So, I removed that line, and restarted.
>
> My archive file is getting updated every 5 minutes as expected.
> HA is seeing fresh weather data via MQTT 15s after the archive time,
> also expected by those who read the VP2 code.
> The reports are failing. In the logs:
>
> Dec 22 13:07:16 wx root: weewx-wait stratum ok 127.0.0.1: stratum 4, 
> offset 0.000054, synch distance 0.076792
> Dec 22 13:10:16 wx -: weewxd[161]: ERROR weewx.reportengine: Caught 
> unrecoverable exception in generator 
> 'weewx.cheetahgenerator.CheetahGenerator'
> Dec 22 13:10:16 wx -: weewxd[161]: ERROR weewx.reportengine: **** Attempt 
> to open a non-existent database archive/weewx.sdb
> Dec 22 13:10:16 wx -: weewxd[161]: ERROR weewx.reportengine: **** 
> Traceback (most recent call last):
> Dec 22 13:10:16 wx -: weewxd[161]: ERROR weewx.reportengine: **** File 
> "/usr/pkg/lib/python3.12/site-packages/weewx/reportengine.py", line 248, in 
> run
> Dec 22 13:10:16 wx -: weewxd[161]: ERROR weewx.reportengine: **** 
> obj.start()
> Dec 22 13:10:16 wx -: weewxd[161]: ERROR weewx.reportengine: **** File 
> "/usr/pkg/lib/python3.12/site-packages/weewx/reportengine.py", line 465, in 
> start
> Dec 22 13:10:16 wx -: weewxd[161]: ERROR weewx.reportengine: **** 
> self.run()
>
> I then -- while in that directory -- did
>
> $ /usr/pkg/bin/weectl-3.12 report run PublicReport
>
> and it's cranking away producing NOAA summaries (I use RAM /tmp for html
> output, trading off having to recreate NOAA files on boot for
> reduced uSD wear).
>
> I reran the report command above while in $HOME, not $HOME/weewx-data,
> and it ran.
>
> Reading the docs at https://www.weewx.com/docs/5.2/usersguide/where/ it
> says that (for pip) the default value of WEEWX_ROOT is ~/weewx-data/
> (not sure why there's a trailing slash). So not setting it should be
> equivalent.
>
> It seems like report generation as invoked after archive interval
> processing is not in the right directory, or not in such a way that it
> inherits WEEWX_ROOT.
>
> So, I'll put it back, and then proceed to ugprading to 5.2.0, but I
> wonder if this is a known issue, or really if I'm confused.
>

-- 
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 visit 
https://groups.google.com/d/msgid/weewx-user/dd405dc2-c7bf-4b75-8bf0-5977039b9ff2n%40googlegroups.com.

Reply via email to