The rain year runs from 1-October-2018 00:00:00 to 1-October-2019 00:00:00,
which is why you're getting the results you are getting.

It's a hack, but you could get what you want by subtracting a second off
the end, then doing your own formatting. It would look something like this:

#import time
#set almost_end = $rainyear.end.raw - 1
#set almost_end_tt = $time.localtime($almost_end)
<p>The end of the rain year is $time.strftime("%B %Y", $almost_end_tt)</p>

On Wed, May 15, 2019 at 7:40 AM steeple ian <[email protected]> wrote:

> I am trying to create an html.tmpl which includes $rainyear starting in
> October. (setting in weewx.conf is 10)
>
>  "$rainyear.start.format(format_string="%B %Y")"; results in "October 2018"
>  "$rainyear.end.format(format_string="%B %Y")"; results in "October 2019"
>
> What I really want is to make rain_year_end to result in "September 2019"
>
> Struggling to get my head round it.
>
> Please can somebody come to my rescue.
>
> Thanks,
> Ian
>
>
> --
> 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/fddb8be6-9987-498b-a205-bfaaf7c99ff5%40googlegroups.com
> <https://groups.google.com/d/msgid/weewx-user/fddb8be6-9987-498b-a205-bfaaf7c99ff5%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CAPq0zEAX0sgYbyMzi9J-dmun_VOumM7gT7Xt7kHzye6a_gGskQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to