Belchertown Graphs, Reports, Records only show Index with parent directory in text.

230 views
Skip to first unread message

lecoqacr...@gmail.com

unread,
Nov 21, 2020, 1:10:58 AM11/21/20
to weewx-user
Have weewx installed on Raspberry pi as a new install using the setup.py method.
Was trying to test the Belchertown skin after an install according to instructions.
The home screen of Belchertown looks normal but the Reports, Graphs and Records tabs only bring up the following :
Index of /home/weewx/public_html/graphs/
NameSizeDate Modified
index.html
13.5 kB
11/20/20, 10:45:19 PM

Weewx.conf is as follows for the StdReport section
[StdReport]
    
    # Where the skins reside, relative to WEEWX_ROOT
    SKIN_ROOT = /home/weewx/skins/
    
    # Where the generated reports should go, relative to WEEWX_ROOT
    HTML_ROOT = /home/weewx/public_html/
    
    # The database binding indicates which data should be used in reports.
    data_binding = wx_binding
    
    # Whether to log a successful operation
    log_success = True
    
    # Whether to log an unsuccessful operation
    log_failure = False
    
    # Each of the following subsections defines a report that will be run.
    # See the customizing guide to change the units, plot types and line
    # colors, modify the fonts, display additional sensor data, and other
    # customizations. Many of those changes can be made here by overriding
    # parameters, or by modifying templates within the skin itself.
    
    [[SeasonsReport]]
        # The SeasonsReport uses the 'Seasons' skin, which contains the
        # images, templates and plots for the report.
        skin = Seasons
        enable = false
    
    [[SmartphoneReport]]
        # The SmartphoneReport uses the 'Smartphone' skin, and the images and
        # files are placed in a dedicated subdirectory.
        skin = Smartphone
        enable = false
        HTML_ROOT = public_html/smartphone
    
    [[MobileReport]]
        # The MobileReport uses the 'Mobile' skin, and the images and files
        # are placed in a dedicated subdirectory.
        skin = Mobile
        enable = false
        HTML_ROOT = public_html/mobile
    
    [[StandardReport]]
        # This is the old "Standard" skin. By default, it is not enabled.
        skin = Standard
        enable = false
    [[Belchertown]]
        skin = Belchertown
        HTML_ROOT = /home/weewx/public_html/Belchertown
        enable = true
    
    [[FTP]]
        # FTP'ing the results to a webserver is treated as just another report,
        # albeit one with an unusual report generator!
        skin = Ftp
        
        # If you wish to use FTP, set "enable" to "true", then
        # fill out the next four lines.
        # Use quotes around passwords to guard against parsing errors.
        enable = false
        user = replace_me
        password = replace_me
        server = replace_me    # The ftp server name, e.g, www.myserver.org
        path = replace_me    # The destination directory, e.g., /weather
        
        # Set to True for an FTP over TLS (FTPS) connection. Not all servers
        # support this.
        secure_ftp = False
        
        # To upload files from something other than what HTML_ROOT is set
        # to above, specify a different HTML_ROOT here.
        #HTML_ROOT = public_html
        
        # Most FTP servers use port 21
        port = 21
        
        # Set to 1 to use passive mode, zero for active mode
        passive = 1
    
    [[RSYNC]]
        # rsync'ing to a webserver is treated as just another report
        skin = Rsync
        
        # If you wish to use rsync, you must configure passwordless ssh using
        # public/private key authentication from the user account that weewx
        # runs to the user account on the remote machine where the files
        # will be copied.
        #
        # If you wish to use rsync, set "enable" to "true", then
        # fill out server, user, and path.
        # The server should appear in your .ssh/config file.
        # The user is the username used in the identity file.
        # The path is the destination directory, such as /var/www/html/weather.
        # Be sure that the user has write permissions on the destination!
        enable = false
        server = replace_me
        user = replace_me
        path = replace_me
        
        # To upload files from something other than what HTML_ROOT is set
        # to above, specify a different HTML_ROOT here.
        #HTML_ROOT = public_html
        
        # Rsync can be configured to remove files from the remote server if
        # they don't exist under HTML_ROOT locally. USE WITH CAUTION: if you
        # make a mistake in the remote path, you could could unintentionally
        # cause unrelated files to be deleted. Set to 1 to enable remote file
        # deletion, zero to allow files to accumulate remotely.
        delete = 0
    What am I missing in my setup to not get the graphs or record plots to show?
Thank you
     

lecoqacr...@gmail.com

unread,
Nov 24, 2020, 10:06:36 AM11/24/20
to weewx-user
Is there no answer to this issue? Pretty sure that it should be a simple fix if someone can point me in the right direction.
the seasons skin shows all graphs but the belchertown only has the output above of the " Parent directory etc." for graphs, records, reports.
Tried on weewx 3.9 with same results using debian install.

ian...@kinnon.org

unread,
Nov 27, 2020, 9:42:14 AM11/27/20
to weewx-user
I am no expert, but sounds like it might be a web server issue rather than weewx/belchertown

Are you see anything in your web server logs?
I am running weewx with belchertown on a raspberry pi Debian 10.6 and my apache logs are in
/var/log/apache2 
check for access.log and error.log

Ian

vince

unread,
Nov 27, 2020, 1:11:42 PM11/27/20
to weewx-user
    [[Belchertown]]
        skin = Belchertown
        HTML_ROOT = /home/weewx/public_html/Belchertown
        enable = true
    

Your HTML_ROOT is putting the Belchertown output into a subdirectory of your web document root.

Try opening http://your.host.name/Belchertown and I suspect you'll see everything....
 

Timothy L

unread,
Dec 3, 2020, 10:26:21 AM12/3/20
to weewx...@googlegroups.com
Thank you for your replies, Ian and Vince. Was out of town for the holiday and will investigate according to your answers. I appreciate  your help.

--
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/326d98b7-6c07-4591-9828-8e67dad6171en%40googlegroups.com.

lecoqacr...@gmail.com

unread,
Dec 6, 2020, 9:42:30 PM12/6/20
to weewx-user
Still haven't been able to get the Belchertown skin to show graphs page or the reports page. I can be sure that the error is due to something I have done or not done correctly.
The following shows up with the developer console (ctrl shift j ) when opening a graphs page from the home Belchertown screen. Maybe this can show something to someone of more understanding than myself.
Maybe I should stick with the seasons skin. It seems to work just as it should. thanks

index.html:31 GET file://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css net::ERR_INVALID_URL
index.html:47 GET file://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js net::ERR_INVALID_URL
index.html:48 GET file://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js net::ERR_INVALID_URL
index.html:50 GET file://code.highcharts.com/stock/highstock.js net::ERR_INVALID_URL
index.html:51 GET file://code.highcharts.com/highcharts-more.js net::ERR_INVALID_URL
index.html:52 GET file://code.highcharts.com/modules/exporting.js net::ERR_INVALID_URL
index.html:53 GET file://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js net::ERR_INVALID_URL
belchertown.js?1607307639:37 Debug: skin.conf belchertown_debug enabled
belchertown.js?1607307639:29 Uncaught ReferenceError: moment is not defined
    at belchertown.js?1607307639:29
(anonymous) @ belchertown.js?1607307639:29
index.html:108 Uncaught ReferenceError: moment is not defined
    at index.html:108
(anonymous) @ index.html:108
responsive-menu.js:1 Uncaught ReferenceError: jQuery is not defined
    at responsive-menu.js:1
(anonymous) @ responsive-menu.js:1
radar.js:8 The AudioContext was not allowed to start. It must be resumed (or created) after a user gesture on the page. https://goo.gl/7K7WLu
l @ radar.js:8


Greg from Oz

unread,
Dec 7, 2020, 12:25:13 AM12/7/20
to weewx-user
You are running it as file://
It should be http:// or https://
The invalid URL is because those sites are NOT locally on your computer.
You only use file:// if the resources are found locally on your computer.

Paul Eaton

unread,
Dec 13, 2020, 10:15:37 AM12/13/20
to weewx-user
Hi lecoqacr...

I had the same problem as you, no charts, trying to run the Belchertown skin "locally" on my Raspberry Pi 4B. It seems the issue is that the chart generator used by Belchertown (called Highcharts) is really intended for making plots on a webpage rather than plotting local data.

So, what you can do is put a web server application onto your Raspberry Pi. There are full details on the web, just google raspberry pi web server, but I installed Apache as per the instructions at www.raspberrypi.org/documentation/remote-access/web-server/apache.md  

All I had to do then was type into my browser http://localhost/weewx/belchertown/ and everything was working properly.

(Note: The above link worked based on my Belchertown index.html file being in the folder /var/www/html/weewx/belchertown - you need to adjust accordingly if it is somewhere else.)

Hope this is of some use.

Regards, Paul


Timothy L

unread,
Dec 17, 2020, 11:11:28 PM12/17/20
to weewx...@googlegroups.com
Thank you Paul, Yes I had managed to access it through a second computer on the lan but was still unsure as to why the localhost call to belchertown would fail. Your answer explains the reason behind this problem with a 
good solution. Maybe if that information can be added to the install instructions for Belchertown it would prevent some problems for those of us who may need a little more help than others. Thank you again.

Reply all
Reply to author
Forward
0 new messages