Page 1 of 1
Intermittent incomplete display of data on website
Posted: Wed 22 Jun 2022 9:59 am
by freddie
Asked on behalf of Michael Lawler (user mdlawler) who can't use this forum:
As the title suggests, Michael is having problems with the display of data on his website being intermittent. He says this:
I'm using Edge Canary, but it happens with the regular version of Edge also. As you can see the data stops displaying after the rain data and the Cumulusmx version displays as a web tag. If I go to
http://lawlers.us/weather and then use f5 or control-f5 I can get it to do this and then the next refresh it will probably display correctly and then the next refresh or two it will mess up again.
Screen shot of this behaviour:
1d915fd3.jpg
I tried accessing Michael's site using Edge (and Chrome also) and couldn't replicate this behaviour. He then asks:
Perhaps this is some type of timing problem that only happens when the server and browser are on the same machine and things are super fast. Could you post this to the forum and see if Neil has any ideas?
Re: Intermittent incomplete display of data on website
Posted: Wed 22 Jun 2022 11:07 am
by flort
I also have this issue and have to refresh the browser to show all the data. I use Edge as my browser. For me, it only started happening after I started using Google Drive Sync. Haven't tried turning it off to see if this resolves the issue.
Regards,
Trevor
Re: Intermittent incomplete display of data on website
Posted: Wed 22 Jun 2022 2:57 pm
by philpugh
I also see this using Edge but not on Firefox or Safari. The page refreshes itself on Edge at the next update period. I also run my web server and CumulusMX software on the same system - RPi 4
Re: Intermittent incomplete display of data on website
Posted: Wed 22 Jun 2022 9:38 pm
by ConligWX
is there any type of cache being used in php? like Zend OPcache or something similar?
or even Leverage browser caching.
I noticed no compression is being used or http/2 protocols on that site as well.
Re: Intermittent incomplete display of data on website
Posted: Thu 23 Jun 2022 5:55 am
by freddie
This is just the default website - no PHP.
Re: Intermittent incomplete display of data on website
Posted: Fri 24 Jun 2022 5:21 pm
by mcrossley
I've been loading that page maybe a hundred times in Edge and did not see the issue!
The data is refreshed once a minute, is the websitedata.json file uploaded once a minute as well?
Does the upload use the FTP Rename option? If not there is a longer window when the file will be partially written to on update and possibly sent by the web site - however if the file was incomplete you would expect the JSON parser to fail.

Re: Intermittent incomplete display of data on website
Posted: Sat 25 Jun 2022 12:35 am
by flort
I generally only see it happen on the initial page load. Subsequent refreshes don't seem to have an issue. It can also happen when moving to a different page on the website but, again, a refresh will fix the issue.
I don't use CMX's built-in FTP functionality. I use a free web hosting service and my account gets blocked if I do. Instead, I upload the websitedata.json file every 2 minutes with LFTP via a Cron job. All other required files are done every 15 minutes.
I also have a local webserver installation visible inside my network which processes the websitedata.json file every minute using the Extra Web Files. This installation allows me to use SQL database as that is not available on the free service.
The issue of the page not fully loading happens on both the internal and external website which points to the issue being with the browser rather than anything else.
Regards,
Trevor
Re: Intermittent incomplete display of data on website
Posted: Sat 25 Jun 2022 9:28 am
by mcrossley
flort wrote: ↑Sat 25 Jun 2022 12:35 am
I generally only see it happen on the initial page load. Subsequent refreshes don't seem to have an issue. It can also happen when moving to a different page on the website but, again, a refresh will fix the issue.
Right, I'll try again...
Re: Intermittent incomplete display of data on website
Posted: Sat 25 Jun 2022 5:57 pm
by mcrossley
OK, I have found the problem and have a solution, I think.
Care to try this new version of the setpagedata script for me?
Re: Intermittent incomplete display of data on website
Posted: Sun 26 Jun 2022 2:42 am
by flort
Hi Mark,
I've tried the new script but am still experiencing the issue.
Regards,
Trevor
Re: Intermittent incomplete display of data on website
Posted: Sun 26 Jun 2022 9:05 am
by mcrossley
Did you flush your browser cache - or Ctrl-F5 the page to ensure you pick up the new version of the script?
Re: Intermittent incomplete display of data on website
Posted: Sun 26 Jun 2022 10:20 am
by flort
No I didn't. I was checking it over several hours and everything was looking good but then it had a failure so I thought there was still an issue. I've now cleared the cache so we'll wait and see if there is a reoccurrence.
Regards,
Trevor
Re: Intermittent incomplete display of data on website
Posted: Mon 27 Jun 2022 4:58 am
by flort
Hi Mark,
I haven't had any further issues with this using the new script so looks like it has worked.
Regards,
Trevor
Re: Intermittent incomplete display of data on website
Posted: Mon 27 Jun 2022 8:11 am
by mcrossley
Great thanks, I'll incorporate the changes in the next release.