Thanks Gary,

There is indeed inline python code in the index.html.tmpl and I will make 
your suggest change to current.inc and see if that fixes it.

On Sunday, March 8, 2020 at 12:45:09 PM UTC, gjr80 wrote:
>
> 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
>
>
>

-- 
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/0cbf784f-6ced-4a37-b413-665be65bcc8c%40googlegroups.com.

Reply via email to