If wind speed is 0, then "cannot decode" message is not seen:

Jun 24 22:20:16 weewxpi weewxd: GaugeGenerator: windSpeed reading = 0.0 
meter_per_second
Jun 24 22:20:16 weewxpi weewxd: GaugeGenerator: windGust reading = 0.0 
meter_per_second
Jun 24 22:20:16 weewxpi weewxd: GaugeGenerator: windDir has no reading 
(None)
Jun 24 22:20:16 weewxpi weewxd: GaugeGenerator: radiation reading = 0.0 
watt_per_meter_squared
Jun 24 22:20:16 weewxpi weewxd: GaugeGenerator: UV reading = 0.0 uv_index


2020 m. birželis 24 d., trečiadienis 19:15:36 UTC+3, Andrej B. rašė:
>
> Good afternoon,
>
> I use Bootstrap theme with Nick gauges (dajda.net). Weewx ver. 4.1 under 
> python 2.7 (Debian Buster)
> In my syslog every archive interval I see hundreds messages like: 
> GaugeGenerator: Cannot decode reading of 'None' for gauge 'windDir'
> This is only happens when wind speed is not None. Below is logfile part:
>
>
>
>
>
>
>
>
>
>
>
> *Jun 24 19:00:15 weewxpi weewxd: GaugeGenerator: outTemp reading = 25.5 
> degree_CJun 24 19:00:15 weewxpi weewxd: GaugeGenerator: inTemp reading = 
> 24.1111111111 degree_CJun 24 19:00:15 weewxpi weewxd: GaugeGenerator: 
> barometer reading = 1022.58763232 mbarJun 24 19:00:15 weewxpi weewxd: 
> GaugeGenerator: outHumidity reading = 49.0 percentJun 24 19:00:15 weewxpi 
> weewxd: GaugeGenerator: inHumidity reading = 56.0 percentJun 24 19:00:16 
> weewxpi weewxd: GaugeGenerator: windSpeed reading = 2.68224 
> meter_per_secondJun 24 19:00:16 weewxpi weewxd: GaugeGenerator: windGust 
> reading = 6.25856 meter_per_secondJun 24 19:00:16 weewxpi weewxd: 
> GaugeGenerator: windDir reading = 0.0 degree_compassJun 24 19:00:16 weewxpi 
> weewxd: GaugeGenerator: Cannot decode reading of 'None' for gauge 
> 'windDir'Jun 24 19:00:16 weewxpi weewxd: GaugeGenerator: Cannot decode 
> reading of 'None' for gauge 'windDir'Jun 24 19:00:16 weewxpi weewxd: 
> GaugeGenerator: Cannot decode reading of 'None' for gauge 'windDir'*
>
> This is part of code responsible for this:
>
> try:
>             history = int(plot_options.get('history'))
>         except:
>             pass
>         else:
>             history_list = []
>             windspeed_history_list = []
>
>             batch_records = 
> self.db_manager.genBatchRecords(self.lastGoodStamp - history * 60 * 60, 
> self.lastGoodStamp)
>
>             for rec in batch_records:
>                 db_value_tuple = weewx.units.as_value_tuple(rec, 
> columnname)
>                 history_value = weewx.units.convert(db_value_tuple, 
> target_unit)[0]
>
>                 try:
>                     history_list.append(float(history_value))
>                 except:
>                     syslog.syslog(syslog.LOG_DEBUG, "GaugeGenerator: 
> Cannot decode reading of '%s' for gauge '%s'"
>                                   % (history_value, gaugename))
>
>
> Why this happens when wind speed has reading?
>
> Thanks
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/fb695639-e5dd-4f0f-b27b-1fd5d68adf07o%40googlegroups.com.

Reply via email to