Skip to content

Commit

Permalink
minor fix: possibility of incorrect labels. bump v0.7.3
Browse files Browse the repository at this point in the history
  • Loading branch information
glennmckechnie committed Sep 7, 2020
1 parent dec5d0a commit 7b9bffd
Show file tree
Hide file tree
Showing 5 changed files with 55 additions and 20 deletions.
25 changes: 15 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,12 @@

**Update: Sept 2020** --- A minor change to note that weewx.conf takes priority over any skin.conf entries. See [How options work](http://weewx.com/docs/customizing.htm#How_options_work) in the Customizing Guide for the full details. This change is required for the label logic when manually changing units to something other than what is in the weewx database. If you have an installation that is already displaying the labels as you want them, then this update is not required.

**Update: Jun 2020** --- Available as [release 0.7.2](https://github.com/glennmckechnie/weewx-wxobs/releases)

Add weewx4 style logging

**Update: Jan 2020**
Available as [release 0.7.3](https://github.com/glennmckechnie/weewx-wxobs/releases)

Runs with python2.7 or python3 ie:- runs under weewx4.

Add logic to detect and create /usr/share/php directory which seems to be missing from some installations, even though phpinfo.php shows it as being available, or required.

----

The remote installation centers around rsyncing an sqlite database to the remote server. If you run an MySQL database then the required configuration for that is built in to mysql and should just require the correct variable names entering. This will vary with each setup so a single configuration example is not in my scope. If you have working notes and wish to share them, then raise them as an issue and we'll start from there.
The remote installation centers around rsyncing an sqlite database to the remote server. If you run an MySQL database then the required configuration for that is built in to mysql and should just require the correct variable names entering. This will vary with each setup so a single configuration example is not in my scope. If you have working notes and wish to share them, then raise them as an issue and we'll start from there.

The weewx-user group is also a starting point for queries.

Expand Down Expand Up @@ -161,7 +155,18 @@ Nothing seems to have broken (for me). It fixed the problem but I'm not knowledg

p.s. datepicker's origins are unknown but a search of github will turn up many versions. I'll find one that matches this one and give a link - [This one](https://github.com/chrishulbert/datepicker) is very close to it.

# Changes
# Previous Changes

**Update: Jun 2020** --- Available as [release 0.7.2](https://github.com/glennmckechnie/weewx-wxobs/releases)

Add weewx4 style logging

**Update: Jan 2020**

Runs with python2.7 or python3 ie:- runs under weewx4.

Add logic to detect and create /usr/share/php directory which seems to be missing from some installations, even though phpinfo.php shows it as being available, or required.

**Update: July 2018** --- Available as [release 0.7.0](https://github.com/glennmckechnie/weewx-wxobs/releases)
Simplify single/average output

Expand Down
4 changes: 2 additions & 2 deletions bin/user/wxobs.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2017 -2020 Glenn McKechnie <[email protected]>
# Copyright (c) 2017-2020 Glenn McKechnie <[email protected]>
# Credit to Tom Keffer <[email protected]>, Matthew Wall and the core
# weewx team, all from whom I've borrowed heavily.
# Mistakes are mine, corrections and or improvements welcomed
Expand All @@ -22,7 +22,7 @@
from weeutil.weeutil import to_bool
from weewx.cheetahgenerator import SearchList

wxobs_version = "0.7.2"
wxobs_version = "0.7.3"

try:
# weewx4 logging
Expand Down
17 changes: 12 additions & 5 deletions install.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,24 @@ def loader():
class wxobsInstaller(ExtensionInstaller):
def __init__(self):
super(wxobsInstaller, self).__init__(
version="0.7.2",
version="0.7.3",
name='wxobs',
description='Generates a php report to show daily summaries',
author="Glenn McKechnie",
author_email="[email protected]",
config={
'StdReport': {
'wxobs': {
'skin': 'wxobs',
'HTML_ROOT': 'wxobs'
}}},
'wxobs': {
'skin': 'wxobs',
'HTML_ROOT': 'wxobs',
'Units': {
'Groups': {
'group_percent': 'percent',
},
},
},
},
},
files=[('bin/user',
['bin/user/wxobs.py']),
('skins/wxobs',
Expand Down
22 changes: 20 additions & 2 deletions skins/wxobs/skin.conf
Original file line number Diff line number Diff line change
Expand Up @@ -252,14 +252,32 @@
# Once you have decided on the units you are using, either those
# provided by the database or ones that you have chosen by configuring
# the [[PHPUnits]] section above, then you need to make a selection
# below for the label units; just as you would for any other weewx skin.
# below for the label units; just as you would for any other weewx
# skin.
#
# The exception is these are purely for use as labels - they have NO
# affect on the values displayed. (unlike if this was a pure python skin)
# affect on the values displayed. (unlike if this was a pure python
# skin)
#
# Weewx will default to Imperial units if there is no adjustment made
# below. Uncomment these and select a suitable option from the # Option
# examples listed at the end of each relevant line.
#
# N.B. For these to take affect they should then be copied to the
# configuration section in weewx.conf, under [StdReport][[wxobs]]
# weewx.conf file. Within that you will find a section that appears
# as follows...
#
# [[wxobs]]
# ...
# [[[Units]]]
# [[[[Groups]]]]
# group_percent = percent
#
# add your entries to the Groups section as per the percentage example.
#
# The why is explained here...
# http://weewx.com/docs/customizing.htm#How_options_work

# group_direction = degree_compass
# group_percent = percent
Expand Down
7 changes: 6 additions & 1 deletion skins/wxobs/wxobs.inc
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
## in Latin-1, then you should replace the string "UTF-8" with "latin-1". If
## you do this, you should also change the charset in 'Content-Type' as well.
#encoding UTF-8
## Copyright 2017-2020 Glenn McKechnie
## php inclusion to create wxobs.php.tmpl by [email protected]
## available at https://github.com/glennmckechnie/weewx-wxobs
## 06-09-2017 initial releas @0.01
Expand Down Expand Up @@ -34,9 +35,13 @@
## index.php. Use dest_dir as switch.
## 14-01-2020 Python3 tweaks. Work around missing /usr/share/php directory. Fix mode
## on os.mkdir
## 00-01-2020 Runs with python2.7 or python3 ie:- runs under weewx4
## 00-06-2020 Available as release 0.7.2 Add weewx4 style logging
## 07-08-2020 Minor change to remedy missing labels when units other than defaults are used.
## Available as release 0.7.3
##
##
## Version 0.7.1
## Version 0.7.3

<!-- wxobs version $wxobs_version -->
<!-- This weewx extension is available at github: https://github.com/glennmckechnie/weewx-wxobs -->
Expand Down

0 comments on commit 7b9bffd

Please sign in to comment.