Mike, Stop looking for 'NoneType', you won't find anything that will help, its just the eror message structure. The clue is in the error message:
Mar 08 09:00:16 raspberrypi weewxd[29345]: weewx[29345] ERROR weewx. cheetahgenerator: **** Ignoring template /home/weewx/skins/Seasons/index. html.tmpl Mar 08 09:00:16 raspberrypi weewxd[29345]: weewx[29345] ERROR weewx. cheetahgenerator: **** Reason: '>' not supported between instances of 'NoneType' and 'float' Mar 08 09:00:16 raspberrypi weewxd[29345]: weewx[29345] ERROR weewx. cheetahgenerator: **** Traceback (most recent call last): Mar 08 09:00:16 raspberrypi weewxd[29345]: weewx[29345] ERROR weewx. cheetahgenerator: **** File "/home/weewx/bin/weewx/cheetahgenerator.py", line 322, in generate Mar 08 09:00:16 raspberrypi weewxd[29345]: weewx[29345] ERROR weewx. cheetahgenerator: **** unicode_string = compiled_template.respond() Mar 08 09:00:16 raspberrypi weewxd[29345]: weewx[29345] ERROR weewx. cheetahgenerator: **** File "_home_weewx_skins_Seasons_index_html_tmpl.py", line …, in respond Mar 08 09:00:16 raspberrypi weewxd[29345]: weewx[29345] ERROR weewx. cheetahgenerator: **** TypeError: '>' not supported between instances of 'NoneType' and 'float' The error indicates there is some in-line python code in the index.html.tmpl template that is comparing the python value None and a float using the > operator. Whilst the error refers to the index.html.tmpl template if you look in that template it actually includes a number of 'includes' ie the contents of other files. So you need to look through them (plus there is no > operator in index.html.tmpl). Actually the only > operator in any of the include files is in hilo.inc and current.inc. It happens ot be the same line of code in each: #if $day.ET.has_data and $day.ET.sum.raw > 0.0 I suspect that is the cause of your issue and its intermittent nature is due to the periodic nature of the ET calculation. In the Seasons skin directory in each of hilo.inc and current.inc try chnaging that line to: #if $day.ET.has_data and $day.ET.sum.raw is not None and $day.ET.sum.raw > 0.0 save the files (no need for restart) and see if the problem disappears. Gary On Sunday, 8 March 2020 20:32:48 UTC+10, Mike Revitt wrote: > > Further update > > After trying all combinations of file refresh I kept getting the same > error so I renamed the weewx directory to weewx.broken and attempted to > reinstall weewx from my previous build, with some interesting results. Bear > in mind that nothing has been changed in the environment since I installed > it yesterday > > pi@raspberrypi:~ $ sudo mv /home/weewx /home/weewx.broken > pi@raspberrypi:~ $ ls -al /home > total 16 > drwxr-xr-x 4 root root 4096 Mar 8 10:12 . > drwxr-xr-x 21 root root 4096 Feb 13 16:32 .. > drwxr-xr-x 21 pi pi 4096 Mar 6 18:18 pi > drwxr-xr-x 8 pi root 4096 Mar 8 10:08 weewx.broken > > pi@raspberrypi:~ $ cd weewx-4.0.0b14/ > pi@raspberrypi:~/weewx-4.0.0b14 $ ./setup.py build > running build > running build_py > running build_scripts > pi@raspberrypi:~/weewx-4.0.0b14 $ sudo ./bin/weewxd weewx.conf > Traceback (most recent call last): > File "./bin/weewxd", line 261, in <module> > main() > File "./bin/weewxd", line 148, in main > engine = weewx.engine.StdEngine(config_dict) > File "/home/pi/weewx-4.0.0b14/bin/weewx/engine.py", line 69, in __init__ > self.setupStation(config_dict) > File "/home/pi/weewx-4.0.0b14/bin/weewx/engine.py", line 87, in > setupStation > driver = config_dict[station_type]['driver'] > File "/usr/lib/python3/dist-packages/configobj.py", line 554, in > __getitem__ > val = dict.__getitem__(self, key) > KeyError: 'unspecified' > pi@raspberrypi:~/weewx-4.0.0b14 $ python -V > Python 3.7.3 > > > > So I logged out and back in, you never know it might have been something > in memory, but that made no difference > > So I deleted the directory weewx-4.0.0b14 and reinstalled it from the zip > file already on disk which is the one I used yesterday > > pi@raspberrypi:~ $ sudo rm -fr weewx-4.0.0b14 > > pi@raspberrypi:~ $ tar xvfz weewx-4.0.0b14.tar.gz > > pi@raspberrypi:~ $ cd weewx-4.0.0b14/ > pi@raspberrypi:~/weewx-4.0.0b14 $ ./setup.py build > running build > running build_py > creating build > > pi@raspberrypi:~/weewx-4.0.0b14 $ sudo ./setup.py install > running install > running build > running build_py > running build_scripts > running install_lib > creating /home/weewx > > I then copied my modified files back , started weewx and compared the > broken directory to the one that is now working > > pi@raspberrypi:/home $ diff -qr weewx weewx.broken/ > Files weewx/archive/weewx.sdb and weewx.broken/archive/weewx.sdb differ > Only in weewx.broken/bin/user/__pycache__: s3backup.cpython-37.pyc > Only in weewx.broken/bin/user/__pycache__: s3upload.cpython-37.pyc > Only in weewx.broken/bin/user/__pycache__: stats.cpython-37.pyc > > pi@raspberrypi:/home $ sudo /etc/init.d/weewx status > ● weewx.service - LSB: weewx weather system > Loaded: loaded (/etc/init.d/weewx; generated) > Active: active (running) since Sun 2020-03-08 10:18:18 GMT; 10min ago > Docs: man:systemd-sysv-generator(8) > Process: 12254 ExecStart=/etc/init.d/weewx start (code=exited, > status=0/SUCCESS) > Tasks: 1 (limit: 2200) > Memory: 37.8M > CGroup: /system.slice/weewx.service > └─12269 /usr/bin/python /home/weewx/bin/weewxd --daemon > --pidfile=/var/run/weewx.pid /home/weewx/weewx.conf > > Mar 08 10:21:20 raspberrypi weewxd[12269]: weewx[12269] INFO > weewx.reportengine: Copied 22 files to /var/www/html/MountWeather > Mar 08 10:21:21 raspberrypi weewxd[12269]: weewx[12269] INFO > botocore.credentials: Found credentials in shared credentials file: > ~/.aws/credentials > Mar 08 10:21:46 raspberrypi weewxd[12269]: weewx[12269] INFO > user.s3upload: S3UploadGenerator: AWS-S3 copied 147 files to S3 in 25.55 > seconds > Mar 08 10:25:15 raspberrypi weewxd[12269]: weewx[12269] INFO > weewx.manager: Added record 2020-03-08 10:25:00 GMT (1583663100) to > database 'weewx.sdb' > Mar 08 10:25:15 raspberrypi weewxd[12269]: weewx[12269] INFO > weewx.manager: Added record 2020-03-08 10:25:00 GMT (1583663100) to daily > summary in 'weewx.sdb' > Mar 08 10:25:17 raspberrypi weewxd[12269]: weewx[12269] INFO > weewx.cheetahgenerator: Generated 7 files for report SeasonsReport in 1.60 > seconds > Mar 08 10:25:18 raspberrypi weewxd[12269]: weewx[12269] INFO > weewx.imagegenerator: Generated 9 images for report SeasonsReport in 0.77 > seconds > Mar 08 10:25:18 raspberrypi weewxd[12269]: weewx[12269] INFO > weewx.reportengine: Copied 0 files to /var/www/html/MountWeather > Mar 08 10:25:18 raspberrypi weewxd[12269]: weewx[12269] INFO > botocore.credentials: Found credentials in shared credentials file: > ~/.aws/credentials > Mar 08 10:25:21 raspberrypi weewxd[12269]: weewx[12269] INFO > user.s3upload: S3UploadGenerator: AWS-S3 copied 16 files to S3 in 3.23 > seconds > > > And it is now running perfectly and nothing is different, although just > ran another diff after it has been running for about 30 minutes and the > only difference now are some cached files > > pi@raspberrypi:/home $ diff -qr weewx weewx.broken/ > Files weewx/archive/weewx.sdb and weewx.broken/archive/weewx.sdb differ > Only in weewx.broken/bin/user/__pycache__: s3backup.cpython-37.pyc > Files weewx/bin/user/__pycache__/s3upload.cpython-37.pyc and > weewx.broken/bin/user/__pycache__/s3upload.cpython-37.pyc differ > Files weewx/bin/user/__pycache__/stats.cpython-37.pyc and > weewx.broken/bin/user/__pycache__/stats.cpython-37.pyc differ > Only in weewx: #S3.last > pi@raspberrypi:/home $ > > > I am hoping someone can help with this as it is stopping me going live on > the Raspberry Pi, and as far as I can tell the environment that works and > the one that doesn't are identical > -- 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/ee813340-9333-4815-b14b-8b1a15d37eaf%40googlegroups.com.
