[[HydroMeteoReport]]
skin = hydrometeo
enable = true
HTML_ROOT = /var/www/html/weewx/hydrometeo
report_timing = */15 * * * *
06/05/20 7:45a 5.8 6.0 5.4 59 -1.5 1.1 NW 0.27 1.6 NW 5.8 5.8 3.9 1015.45 0.00 0.0 14.3 0.0 19.3 46 7.4 19.3 8.72 1.2087 0 7 99.9 15
06/05/20 8:00a 6.6 7.1 6.1 56 -1.5 0.0 N/A 0.00 0.0 N/A 6.6 6.6 4.7 1015.46 0.00 0.0 14.3 0.0 19.4 46 7.4 19.4 8.72 1.2084 0 7 97.9 15
06/05/20 8:15a 7.8 8.1 7.4 54 -1.0 0.0 N/A 0.00 0.0 N/A 7.8 7.8 5.8 1015.45 0.00 0.0 14.3 0.0 19.4 45 7.3 19.4 8.62 1.2081 0 7 99.9 15
06/05/20 8:30a 8.0 8.3 7.8 52 -1.2 2.7 WNW 0.67 4.8 WNW 8.0 8.0 6.1 1015.39 0.00 0.0 14.3 0.0 19.6 45 7.4 19.6 8.56 1.2073 0 7 99.9 15
06/05/20 8:45a 8.2 8.6 7.8 50 -1.5 2.7 E 0.67 3.2 W 8.2 8.2 6.3 1015.33 0.00 0.0 14.3 0.0 19.9 45 7.6 19.9 8.56 1.2061 0 7 99.9 15
06/05/20 9:00a 9.0 9.1 8.8 48 -1.6 2.1 NE 0.54 3.2 ENE 9.0 9.0 7.0 1015.31 0.00 0.0 14.3 0.0 19.9 45 7.6 19.9 8.56 1.2061 0 7 98.9 15
06/05/20 9:15a 9.1 9.3 9.0 48 -1.4 1.1 NE 0.27 1.6 ENE 9.1 9.1 7.2 1015.14 0.00 0.0 14.3 0.0 20.1 44 7.6 20.1 8.45 1.2051 0 7 98.9 15
06/05/20 9:30a 9.9 10.0 9.8 46 -1.2 0.5 NNE 0.13 1.6 NNE 9.9 9.9 8.0 1015.02 0.00 0.0 14.3 0.0 20.0 44 7.4 20.0 8.40 1.2053 0 7 98.9 15
06/05/20 9:45a 9.7 9.7 9.6 46 -1.4 0.0 N/A 0.00 0.0 N/A 9.7 9.7 7.7 1014.99 0.00 0.0 14.3 0.0 20.0 44 7.4 20.0 8.40 1.2053 0 7 99.9 15
06/05/20 10:00a 9.8 9.8 9.8 45 -1.6 0.5 E 0.13 1.6 E 9.8 9.8 7.9 1014.77 0.00 0.0 14.3 0.0 20.0 44 7.4 20.0 8.40 1.2050 0 7 99.9 15
06/05/20 10:15a 10.0 10.2 9.8 45 -1.5 0.0 N/A 0.00 0.0 N/A 10.0 10.0 8.1 1014.66 0.00 0.0 14.3 0.0 20.0 44 7.4 20.0 8.40 1.2049 0 7 99.9 15
06/05/20 10:30a 10.1 10.3 9.9 43 -1.8 2.7 WNW 0.67 3.2 NW 10.1 10.1 8.2 1014.57 0.00 0.0 14.3 0.0 20.0 44 7.4 20.0 8.40 1.2048 0 7 99.9 15
06/05/20 10:45a 0.0 0.0 0.0 0.0 0.0 0.0 N/A 0.00 0.0 N/A 0.0 0.0 0.0 N/A 0.00 0.0 14.3 0.0 0.0 N/A 0.0 0.0 0.00 0.0000 0 7 0.0 15 --
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/20d610d8-5ef6-4225-8f6a-808bc70e8650%40googlegroups.com.
#errorCatcher Echo
#import weewx.uwxutils as utils
#import user.weathercalc as wc
#set $D="%d/%m/%y"
#set $Time="%I:%M%p"
#set $N50f="%5.0f"
#set $N51f="%5.1f"
#set $N52f="%5.2f"
#set $NONE0F="0"
#set $NONE1F="0.0"
#set $NA="N/A"
#set $NONE2F="0.00"
#set $NONE3F="0.000"
#def formatTime($raw):
#from datetime import datetime
#echo $datetime.fromtimestamp($raw).strftime("%-I:%M%p").lower().rstrip('m').rjust(6)
#end def
Temp Hi Low Out Dew Wind Wind Wind Hi Hi Wind Heat THW Rain Heat Cool In In In In In In Air Wind Wind ISS Arc.
Date Time Out Temp Temp Hum Pt. Speed Dir Run Speed Dir Chill Index Index Bar Rain Rate D-D D-D Temp Hum Dew Heat EMC Density Samp Tx Recept Int.
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
#for $_span in $last2days
$_span.start.format($D) #slurp ## DATE
$self.formatTime($_span.start.raw) #slurp ## TIME
$_span.outTemp.avg.nolabel($N51f,$NONE1F).rjust(6) #slurp ## TEMP OUT
$_span.outTemp.max.nolabel($N51f,$NONE1F).rjust(6) #slurp ## HI TEMP
$_span.outTemp.min.nolabel($N51f,$NONE1F).rjust(6) #slurp ## LOW TEMP
$_span.outHumidity.avg.nolabel($N50f,$NONE1F).rjust(5) #slurp ## OUT HUM
$_span.dewpoint.avg.nolabel($N51f,$NONE1F).rjust(6) #slurp ## DEW PT.
$_span.windSpeed.avg.nolabel($N51f,$NONE1F).rjust(5) #slurp ## WIND SPEED
$_span.windDir.avg.ordinal_compass.format(None_string="---").rjust(5) #slurp ## WIND DIR
$_span.windrun.sum.nolabel($N52f,$NONE2F).rjust(6) #slurp ## WIND RUN
$_span.windSpeed.max.nolabel($N51f,$NONE1F).rjust(5) #slurp ## HI SPEED
$_span.windDir.max.ordinal_compass.format(None_string="---").rjust(5) #slurp ## HI DIR
$_span.windchill.avg.nolabel($N51f,$NONE1F).rjust(6) #slurp ## WIND CHILL
$_span.heatindex.avg.nolabel($N51f,$NONE1F).rjust(6) #slurp ## HEAT INDEX
$wc.CalculateTHWIndex($_span.heatIndex.avg.raw,$span.windSpeed.avg.raw).rjust(6) #slurp ## THW INDEX
$_span.barometer.avg.nolabel($N52f).rjust(7) #slurp ## BAR
$_span.rain.sum.nolabel($N52f,$NONE2F).rjust(5) #slurp ## RAIN
$_span.rainRate.avg.nolabel($N51f,$NONE1F).rjust(5) #slurp ## RAIN RATE
$_span.heatdeg.avg.nolabel($N51f,$NONE1F).rjust(7) #slurp ## HEAT D-D
$_span.cooldeg.avg.nolabel($N51f,$NONE1F).rjust(7) #slurp ## COOL D-D
$_span.inTemp.avg.nolabel($N51f,$NONE1F).rjust(6) #slurp ## IN TEMP
$_span.inHumidity.avg.nolabel($N50f,$NA).rjust(5) #slurp ##IN HUM
$wc.CalculateDewPoint($_span.inTemp.avg.raw,$_span.inHumidity.avg.raw).rjust(6) #slurp ## IN DEW
$wc.CalculateHeatIndex($_span.inTemp.avg.raw,$_span.inHumidity.avg.raw).rjust(6) #slurp ## IN HEAT
$wc.CalculateEMC($_span.inTemp.avg.raw,$_span.inHumidity.avg.raw).rjust(6) #slurp ## IN EMC
$wc.CalculateAirDensity($_span.inTemp.avg.raw,$_span.pressure.avg.raw).rjust(6) #slurp ## IN AIR DENSITY
0 #slurp ## WIND SAMPLES
7 #slurp ## TRANSMITTER ID
$_span.rxCheckPercent.last.nolabel($N51f,$NONE1F).rjust(8) #slurp ## IIS RECEPTION QUALITY
15 ## ARCHIVE INTERVAL
#end for
To unsubscribe from this group and stop receiving emails from it, send an email to weewx...@googlegroups.com.
This code generates last2days
--
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/973a62ae-07c2-4719-9a9f-a3a6fd790aea%40googlegroups.com.
Roger that. What would be the best way for me to debug this ? Do you have a setup to recommend. It’s been my main issue debugging this python in Weewx. Since my knowledge lacks in debugging a linux environment I`ve been looking mostly at the logs of weewx but surely you must have some kind of setup or debugger you can attach to the process and see variables and do a step by step ?
Thank.
--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/MFnpwI8sGNQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/CAPq0zEDzDBetcyTH30OCjkSV1Y45_See0dDwxonf5gzBWh97qg%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/001801d623c3%24ebbb16b0%24c3314410%24%40gmail.com.
PyCharm why didn’t think of that IDE. I know jetbrains I`ve used their tools like Resharper for C#.
Thanks.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/CAPq0zEA0Csu%3DOUCSd3dPBGT05vZ%3DrBXDE9HSdexEXJTjbu9%2BCQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/002b01d623c4%24bad82d20%2430888760%24%40gmail.com.
I would hazard a guess and say your issue is using datetime.datetime.now() in your search list extension. That time is being used as your stop/end time for the report and is (roughly) the time the report is run. This will be after the current (and last) record in the archive. So when the report is run anything in the last row that relies on the last record will be 0 or None.
I would try using timespan.stop instead. This will give you the actual timestamp if the last/current archive record as the end point.
I am always wary of using the current system time in a SLE.
But I could be wrong...
Gary
Interesting Gary. Makes a lot of sense. I will try that and let you know what happens. Thanks for your input
-----Original Message-----
From: weewx...@googlegroups.com <weewx...@googlegroups.com> On Behalf Of gjr80
Sent: May 6, 2020 14:48
To: weewx-user <weewx...@googlegroups.com>
Subject: Re: [weewx-user] Issue with a report last values are Zero
Hi,
I would hazard a guess and say your issue is using datetime.datetime.now() in your search list extension. That time is being used as your stop/end time for the report and is (roughly) the time the report is run. This will be after the current (and last) record in the archive. So when the report is run anything in the last row that relies on the last record will be 0 or None.
I would try using timespan.stop instead. This will give you the actual timestamp if the last/current archive record as the end point.
I am always wary of using the current system time in a SLE.
But I could be wrong...
Gary
--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/MFnpwI8sGNQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+unsubscribe@googlegroups.com.
08/05/20 11:45a 0.0 0.0 0.0 0.0 0.0 0.0
08/05/20 12:00p 0.3 0.4 0.3 80 -2.7 0.0
08/05/20 12:15p 0.1 0.2 -0.0 80 -2.9 0.008/05/20 11:45a 0.0 0.0 0.0 0.0 0.0 0.0
08/05/20 12:00p 0.3 0.4 0.3 80 -2.7 0.0
08/05/20 12:15p 0.1 0.2 -0.0 80 -2.9 0.008/05/20 11:45a 0.0 0.0 0.0 0.0 0.0 0.0
08/05/20 12:00p 0.3 0.4 0.3 80 -2.7 0.0
08/05/20 12:15p 0.1 0.2 -0.0 80 -2.9 0.0
08/05/20 12:30p -0.1 -0.1 -0.1 80 -3.2 0.0Oh an by the way : On the latest release page on the latest release itself on github instructions are pointing to the github page with the code and not the page itself.
Temp Hi Low Out Dew Wind Wind Wind Hi Hi Wind Heat THW Rain Heat Cool In In In In In In Air Wind Wind ISS Arc.
Date Time Out Temp Temp Hum Pt. Speed Dir Run Speed Dir Chill Index Index Bar Rain Rate D-D D-D Temp Hum Dew Heat EMC Density Samp Tx Recept Int.
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
09/05/20 12:15a 1.2 1.2 1.1 55 -6.9 5.4 NW 1.3 6.4 NW 0.5 1.2 31.8 1008.1 0.0 0.0 16.6 0.0 19.9 45 7.6 19.9 8.56 1.2067 0 7 92.0 15
09/05/20 12:30a 1.1 1.1 1.1 53 -7.3 5.4 NW 1.3 6.4 NW 0.4 1.1 31.6 1008.2 0.0 0.0 16.6 0.0 19.8 45 7.5 19.8 8.56 1.2072 0 7 99.9 15
09/05/20 12:45a 0.9 1.0 0.9 53 -7.6 4.8 NW 1.2 4.8 NW 0.9 0.9 31.3 1008.2 0.0 0.0 16.6 0.0 19.8 45 7.5 19.8 8.56 1.2075 0 7 99.9 15
09/05/20 1:00a 0.8 0.8 0.8 53 -7.7 5.4 NW 1.3 6.4 NW 0.2 0.8 31.1 1008.2 0.0 0.0 16.6 0.0 19.7 45 7.5 19.7 8.56 1.2076 0 7 88.8 15
09/05/20 1:15a 0.8 0.8 0.8 52 -8.0 6.4 NW 1.6 6.4 NW -1.3 0.8 31.0 1008.3 0.0 0.0 16.6 0.0 19.6 45 7.3 19.6 8.56 1.2082 0 7 99.9 15
09/05/20 1:30a 0.7 0.8 0.7 51 -8.2 6.4 NW 1.6 6.4 NW -1.3 0.7 31.0 1008.4 0.0 0.0 16.6 0.0 19.5 45 7.3 19.5 8.57 1.2086 0 7 95.0 15
09/05/20 1:45a 0.6 0.7 0.6 51 -8.3 7.5 NW 1.9 8.0 NW -1.8 0.6 30.8 1008.3 0.0 0.0 16.6 0.0 19.5 45 7.3 19.5 8.57 1.2086 0 7 86.2 15
09/05/20 2:00a 0.5 0.6 0.5 50 -8.7 8.6 NW 2.1 9.7 NW -2.3 0.5 30.6 1008.4 0.0 0.0 16.6 0.0 19.5 45 7.2 19.5 8.57 1.2090 0 7 99.9 15
09/05/20 2:15a 0.4 0.4 0.3 50 -8.8 6.4 NW 1.6 8.0 NW -1.2 0.4 30.3 1008.5 0.0 0.0 16.6 0.0 19.4 45 7.2 19.4 8.57 1.2093 0 7 99.6 15
09/05/20 2:30a 0.4 0.4 0.3 50 -8.8 8.6 NW 2.1 9.7 NW -2.4 0.4 30.3 1008.5 0.0 0.0 16.6 0.0 19.3 45 7.1 19.3 8.57 1.2096 0 7 99.9 15
09/05/20 2:45a 0.3 0.3 0.2 51 -8.7 8.6 NW 2.1 9.7 NW -2.6 0.3 30.1 1008.5 0.0 0.0 16.6 0.0 19.3 45 7.0 19.3 8.57 1.2098 0 7 99.9 15
09/05/20 3:00a 0.1 0.2 -0.1 52 -8.5 3.8 NW 0.9 6.4 NW -0.7 0.1 29.7 1008.5 0.0 0.0 16.6 0.0 19.2 45 7.0 19.2 8.57 1.2100 0 7 99.2 15 --
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/9fb36d12-a36c-4e7d-93ba-1dc94bab233a%40googlegroups.com.