It is currently October 24th, 2020, 6:00 am

Weather.com JSON not loading correctly

General topics related to Rainmeter.
dvo
Posts: 1017
Joined: February 7th, 2016, 6:08 am

Re: ⭐ Weather.com JSON not loading correctly

Post by dvo »

btw shortcut of internet options is : C:\Windows\System32\inetcpl.cpl
User avatar
Yincognito
Posts: 2769
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: ⭐ Weather.com JSON not loading correctly

Post by Yincognito »

nek wrote: May 27th, 2020, 5:56 am Q3. How to solve this problems?
A3. I recomend you to append the UserAgent in the skin file like this.

Code: Select all

[MeasureWebParser]
Measure=WebParser
;;desktop version.
UserAgent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.61 Safari/537.36
...
I guess the weather.com is testing/preparing for this.
Just tried your suggested method, and unfortunately, in my case, it didn't work (same results in jsmorley's JSON parsing skin, by the way):
Desktop User Agent.jpg
Will try again the way jsmorley suggested, not necessarily to fix things (because I know they'll come back sooner or later) but to make another save of the page the "old way", if possible.
You do not have the required permissions to view the files attached to this post.
User avatar
jsmorley
Developer
Posts: 21424
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: ⭐ Weather.com JSON not loading correctly

Post by jsmorley »

Yincognito wrote: May 27th, 2020, 12:06 pm Just tried your suggested method, and unfortunately, in my case, it didn't work (same results in jsmorley's JSON parsing skin, by the way):
Desktop User Agent.jpg
Will try again the way jsmorley suggested, not necessarily to fix things (because I know they'll come back sooner or later) but to make another save of the page the "old way", if possible.
Yeah, I don't think UserAgent in and of itself fixes the problem. Didn't for me anyway. The only thing that has consistent results for me is deleting any cookies IE sets for the site when the problem presents itself.
User avatar
Yincognito
Posts: 2769
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: ⭐ Weather.com JSON not loading correctly

Post by Yincognito »

jsmorley wrote: May 27th, 2020, 12:07 pm Yeah, I don't think UserAgent in and of itself fixes the problem. Didn't for me anyway. The only thing that has consistent results for me is deleting any cookies IE sets for the site when the problem presents itself.
Indeed. As expected, tried according to your advice and it worked. Now I can eagerly wait for it to break again, so I can make an accurate comparison (as my previously saved samples were taken using different URL query parameters) between the two page sources - I wonder how much it will take for it to break again this time, LOL. In the meantime, back to carefully setting up what I would like to be an adaptive regex for various versions (since they're just 3, with one of them probably already obsolete) - let's see if it's 100% possible.

One other thing ... maybe one could investigate what cookies exactly are causing this, by using NirSoft's EdgeCookiesView. Not that would solve anything, because those cookies will come back sooner or later, but at least to help identify where the issue is coming from. I already downloaded the tool and will take a look, but it would help to have more eyes on this, maybe what one of us misses the other notices...

EDIT: Another tool that can help with sending a lot of different types of requests for a particular URL, beautifying the response, and visualising cookies (including session cookies, that NirSoft's EdgeCookiesView apparently doesn't show) is Postman. Unfortunately, when beautifying the source, it only dos it for the HTML part and not the Javascript part, which remains unindented - probably its only flaw, so far. Certainly easier to handle than analyzing packets using Wireshark network protocol analyzer in the search for a clue on this...
Last edited by Yincognito on May 27th, 2020, 3:01 pm, edited 1 time in total.
User avatar
ryanchuang
Posts: 30
Joined: September 13th, 2019, 4:23 am

Re: ⭐ Weather.com JSON not loading correctly

Post by ryanchuang »

I did the ccleaner method,however,it broke really quick after working for few minutes.
dvo
Posts: 1017
Joined: February 7th, 2016, 6:08 am

Re: ⭐ Weather.com JSON not loading correctly

Post by dvo »

strange it works here, from the last glitch yesterday evening... :)
User avatar
pul53dr1v3r
Posts: 406
Joined: July 30th, 2014, 10:30 am

Re: ⭐ Weather.com JSON not loading correctly

Post by pul53dr1v3r »

i just noticed new weather.com site design for the first time:

Image
(just in case: click "Open image (link) in new tab" to see the image in full size)

It could be the culprit for headache we're having with the weather skins.
User avatar
xenium
Posts: 555
Joined: January 4th, 2018, 9:52 pm

Re: ⭐ Weather.com JSON not loading correctly

Post by xenium »

pul53dr1v3r wrote: May 28th, 2020, 4:24 pm i just noticed new weather.com site design for the first time:
It could be the culprit for headache we're having with the weather skins.
Strange.
I don't have the new design..
User avatar
jsmorley
Developer
Posts: 21424
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: ⭐ Weather.com JSON not loading correctly

Post by jsmorley »

Yeah, I like the new design, but it really doesn't have anything to do with the JSON.


1.jpg
You do not have the required permissions to view the files attached to this post.
User avatar
SilverAzide
Posts: 969
Joined: March 23rd, 2015, 5:26 pm

Re: ⭐ Weather.com JSON not loading correctly

Post by SilverAzide »

xenium wrote: May 28th, 2020, 5:04 pm Strange.
I don't have the new design..
I don't have this new design either... UNLESS I change the user agent string to one for Android. If you set it to:
Mozilla/5.0 (Linux; Android 10; Pixel 4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.61 Mobile Safari/537.36
you'll get the new page.
Gadgets Wiki GitHub More Gadgets...