Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WX4.0.0b14 & Bskin1.1b9 - a couple of issues that works before #261

Closed
ZXant opened this issue Mar 15, 2020 · 6 comments
Closed

WX4.0.0b14 & Bskin1.1b9 - a couple of issues that works before #261

ZXant opened this issue Mar 15, 2020 · 6 comments

Comments

@ZXant
Copy link

ZXant commented Mar 15, 2020

  1. skin.conf
    Including "cloudbase", calculated by WeeWX software, in station_observations cause error (not sure if other variables may also cause difficulties).

  2. graph.conf
    I used to calculate Illuminance as a multiplier of maxSolarRad from HighCharts (observation_type), but now produce error:
    [[[maxSolarRad]]]
    name = Illuminance
    yAxis = 1
    type = area
    fillOpacity = 0.2
    color = "#f7f2b4"
    yAxis_visible = false
    observation_type = 120.0*maxSolarRad

Both instances used to work in previous official releases of WeeWX and Bskin, but no longer.

Best, Xant

@poblabs
Copy link
Owner

poblabs commented Mar 15, 2020

Which error does it cause? Can you provide the full output?

I need more information here. Also please upgrade to weewx b15 which came out and see if the problems exist with that version.

@ZXant
Copy link
Author

ZXant commented Mar 15, 2020

Updated to b15.... same issue.

Skin.conf: station_observations = "barometer", "outHumidity", "dewpoint", "rainWithRainRate", "maxSolarRad", "radiation", "cloudbase"

root@RPi4:/etc/weewx# service weewx start
root@RPi4:/etc/weewx# wee_reports
Using configuration file /etc/weewx/weewx.conf
Generating for all time
Traceback (most recent call last):
  File "/usr/share/weewx/weewx/reportengine.py", line 197, in run
    obj.start()
  File "/usr/share/weewx/weewx/reportengine.py", line 280, in start
    self.run()
  File "/usr/share/weewx/weewx/cheetahgenerator.py", line 150, in run
    ngen = self.generate(gen_dict[section_name], self.gen_ts)
  File "/usr/share/weewx/weewx/cheetahgenerator.py", line 220, in generate
    ngen += self.generate(section[subsection], gen_ts)
  File "/usr/share/weewx/weewx/cheetahgenerator.py", line 220, in generate
    ngen += self.generate(section[subsection], gen_ts)
  File "/usr/share/weewx/weewx/cheetahgenerator.py", line 309, in generate
    default_binding)
  File "/usr/share/weewx/weewx/cheetahgenerator.py", line 376, in _getSearchList
    searchList += obj.get_extension_list(timespan, db_lookup)
  File "/usr/share/weewx/user/belchertown.py", line 836, in get_extension_list
    obs_output = getattr(current, obs)
  File "/usr/share/weewx/weewx/tags.py", line 457, in __getattr__
    vt = weewx.xtypes.get_scalar(obs_type, self.record, db_manager)
  File "/usr/share/weewx/weewx/xtypes.py", line 71, in get_scalar
    return xtype.get_scalar(obs_type, record, db_manager)
  File "/usr/share/weewx/weewx/wxservices.py", line 252, in get_scalar
    return getattr(self, method_name)(obs_type, record, db_manager)
  File "/usr/share/weewx/weewx/wxservices.py", line 274, in calc_cloudbase
    if 'outTemp' not in data or 'outHumidity' not in data:
TypeError: argument of type 'NoneType' is not iterable

Without "cloudbase", no error.

@ZXant ZXant closed this as completed Mar 15, 2020
@poblabs
Copy link
Owner

poblabs commented Mar 15, 2020

Looks like you closed this. The error points to weewx, not Belchertown skin.

  File "/usr/share/weewx/weewx/wxservices.py", line 274, in calc_cloudbase
    if 'outTemp' not in data or 'outHumidity' not in data:

@ZXant ZXant reopened this Mar 15, 2020
@ZXant
Copy link
Author

ZXant commented Mar 15, 2020

Agree... pls, disregard #1

  1. graph.conf

[[chart5]] title = Illuminance & UV type = spline yAxis_min = 0 [[[radiation]]] name = Radiation yIndex = 1 [[[maxSolarRad]]] name = Illuminance type = area fillOpacity = 0.2 color = "#f7f2b4" yAxis = 0 yAxis_label = "Illuminance (lux)" observation_type = 120.0*maxSolarRad [[[UV]]] name = UV Index yAxis = 1 yAxis_label = "UV Index" yAxis_min = 0 yAxis_max = 16 color = "#90ed7d" zIndex = 2

The multiplier (times 120) used to work before. Error as the following:

root@RPi4:~/DN/weewx-4.0.0b15# service weewx start root@RPi4:~/DN/weewx-4.0.0b15# wee_reports Using configuration file /etc/weewx/weewx.conf Generating for all time Traceback (most recent call last): File "/usr/share/weewx/weewx/reportengine.py", line 197, in run obj.start() File "/usr/share/weewx/weewx/reportengine.py", line 280, in start self.run() File "/usr/share/weewx/user/belchertown.py", line 1370, in run series_data = self.get_observation_data(binding, archive, observation_type, minstamp, maxstamp, aggregate_type, aggregate_interval, time_length, xAxis_groupby, xAxis_categories, mirrored_value, weatherRange_obs_lookup) File "/usr/share/weewx/user/belchertown.py", line 1823, in get_observation_data raise Warning( "Error trying to use database binding %s to graph observation %s. Error was: %s." % (binding, obs_lookup, e) ) Warning: Error trying to use database binding wx_binding to graph observation 120.0*maxSolarRad. Error was: 120.0*maxSolarRad. root@RPi4:~/DN/weewx-4.0.0b15#

@poblabs
Copy link
Owner

poblabs commented Apr 8, 2020

Are you sure this was working before? What versions was it working on previously?

@poblabs
Copy link
Owner

poblabs commented Apr 8, 2020

The observation_type is the name of the column in the database. I don't see how you'd be able to do any math on that. I'm very confused here. Are you sure you didn't modify something to make this work?

@poblabs poblabs closed this as completed Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants