Guest - Testers are needed for the reworked CDateTime core component. See... https://forum.kodi.tv/showthread.php?tid=378981 (September 29) x
  • 1
  • 16
  • 17
  • 18(current)
  • 19
  • 20
  • 25
Broken Multi Weather
Hello,
In France.
url 'https://www.yahoo.com/?guccounter=1' failed.
Same issue with url 'https://www.yahoo.com/news/weather/?guccounter=1'.

url 'https://www.yahoo.com/?guccounter=2' and 'https://www.yahoo.com/?guccounter=' are ok.

Can you try url 'https://www.yahoo.com/?guccounter=' in your contry ?
Reply
In UK Multi Weather stopped working today (30 Jan 2024).

Changed to CURL = 'https://www.yahoo.com/?guccounter=1' 

from CURL = 'https://www.yahoo.com/?guccounter=2'

Seems all good now on CoreElec 20.2. Add-on version 0.0.22
Reply
i'm a bit at a loss on what's going on with this...
no idea if different countries need a different url these days,
or whether they regularly change the url or not.

for me, most of the mentioned url's work fine (only the 'guccounter=2' doesn't work on my end).

so i've made a version which tries all of the url's mentioned above, until it gets the cookie it needs:
weather.multi-0.0.24.zip
weather.multi-0.0.25.zip

please test if you're interested and let me know how it goes.
thx!
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
(2024-02-01, 02:11)ronie Wrote: weather.multi-0.0.24.zip

please test if you're interested and let me know how it goes.
thx!
Working for Germany. Thx.
https://paste.kodi.tv/paviyihibi.kodi
Reply
(2024-02-01, 02:11)ronie Wrote: i'm a bit at a loss on what's going on with this...
no idea if different countries need a different url these days,
or whether they regularly change the url or not.

for me, most of the mentioned url's work fine (only the 'guccounter=2' doesn't work on my end).

so i've made a version which tries all of the url's mentioned above, until it gets the cookie it needs:
weather.multi-0.0.24.zip

please test if you're interested and let me know how it goes.
thx!

I wonder if it would be instructive or helpful to store the "successful" URL in the "settings.xml" file...

Perhaps the URL could then be viewed or changed through the Add-on "settings" interface?

Just an idea.

Thanks.
Reply
Hello,
Have tested version weather.multi-0.0.24.zip but it don't work in France.

Partial kodi.log -> ko
Quote:2024-02-02 11:30:06.886 T:6464    debug <general>: CPythonInvoker(7, C:\Users\nic020\AppData\Roaming\Kodi\addons\weather.multi\default.py): instantiating addon using automatically obtained id of "weather.multi" dependent on version 3.0.0 of the xbmc.python api
2024-02-02 11:30:07.541 T:6464    debug <general>: weather.multi: version 0.0.24 started: ['C:\\Users\\nic020\\AppData\\Roaming\\Kodi\\addons\\weather.multi\\default.py', '1']
2024-02-02 11:30:07.541 T:6464    debug <general>: weather.multi: location: Paris, Ile-de-France, FR
2024-02-02 11:30:07.541 T:6464    debug <general>: weather.multi: location id: 615702
2024-02-02 11:30:07.541 T:6464    debug <general>: weather.multi: cookie from settings:
2024-02-02 11:30:07.541 T:6464    debug <general>: weather.multi: crumb from settings:
2024-02-02 11:30:07.541 T:6464    debug <general>: weather.multi: stamp from settings:
2024-02-02 11:30:09.042 T:10000   debug <general>: CAESinkDirectSound:Big Grineinitialize: Cleaning up
2024-02-02 11:30:09.324 T:6464    debug <general>: weather.multi: EU user
2024-02-02 11:30:09.325 T:6464    debug <general>: weather.multi: EU token: Y2sqd3A
2024-02-02 11:30:09.325 T:6464    debug <general>: weather.multi: EU sessionid: 3_cc-session_6a87944a-cb40-45ac-b23b-1da62e98b8ac
2024-02-02 11:30:09.325 T:6464    debug <general>: weather.multi: EU redirect https://www.yahoo.com/?guccounter&#x3D;1
2024-02-02 11:30:10.060 T:6464    debug <general>: weather.multi: cookies: <RequestsCookieJar[]>
2024-02-02 11:30:11.574 T:5300     info <general>: Skipped 3 duplicate messages..
2024-02-02 11:30:11.574 T:5300    debug <general>: ------ Window Init (Pointer.xml) ------
2024-02-02 11:30:11.982 T:6464    debug <general>: weather.multi: cookies: <RequestsCookieJar[]>
2024-02-02 11:30:12.431 T:6464    debug <general>: weather.multi: save cookie to settings:
2024-02-02 11:30:12.431 T:6464    debug <general>: weather.multi: save crumb to settings: 5YY5smmobLY
2024-02-02 11:30:12.432 T:6464    debug <general>: weather.multi: save stamp to settings: 1706869812
2024-02-02 11:30:12.432 T:6464    debug <general>: weather.multi: no cookie
2024-02-02 11:30:12.432 T:6464    debug <general>: weather.multi: available locations: 1
2024-02-02 11:30:12.432 T:6464    debug <general>: weather.multi: finished
2024-02-02 11:30:12.432 T:6464    debug <general>: CPythonInvoker(7, C:\Users\nic020\AppData\Roaming\Kodi\addons\weather.multi\default.py): script successfully run

After some searches, I found it's because ysess Session() was already open.
To fix, I moved line 89 to line 99 in file weather.py and in kodi.log you can see that Weather.multi check all url to find  cookies.

kodi.log with patch -> ok
Quote:2024-02-02 11:33:32.520 T:8372    debug <general>: CPythonInvoker(7, C:\Users\nic020\AppData\Roaming\Kodi\addons\weather.multi\default.py): instantiating addon using automatically obtained id of "weather.multi" dependent on version 3.0.0 of the xbmc.python api
2024-02-02 11:33:33.166 T:8372    debug <general>: weather.multi: version 0.0.24 started: ['C:\\Users\\nic020\\AppData\\Roaming\\Kodi\\addons\\weather.multi\\default.py', '1']
2024-02-02 11:33:33.166 T:8372    debug <general>: weather.multi: location: Paris, Ile-de-France, FR
2024-02-02 11:33:33.166 T:8372    debug <general>: weather.multi: location id: 615702
2024-02-02 11:33:33.166 T:8372    debug <general>: weather.multi: cookie from settings:
2024-02-02 11:33:33.166 T:8372    debug <general>: weather.multi: crumb from settings:
2024-02-02 11:33:33.166 T:8372    debug <general>: weather.multi: stamp from settings:
2024-02-02 11:33:34.965 T:8372    debug <general>: weather.multi: EU user
2024-02-02 11:33:34.967 T:8372    debug <general>: weather.multi: EU token: CeYDObM
2024-02-02 11:33:34.967 T:8372    debug <general>: weather.multi: EU sessionid: 3_cc-session_d7a4657c-3067-44e3-9077-22d26491e3da
2024-02-02 11:33:34.967 T:8372    debug <general>: weather.multi: EU redirect https://www.yahoo.com/?guccounter&#x3D;1
2024-02-02 11:33:35.745 T:8372    debug <general>: weather.multi: cookies: <RequestsCookieJar[]>
2024-02-02 11:33:36.461 T:8372    debug <general>: weather.multi: EU user
2024-02-02 11:33:36.462 T:8372    debug <general>: weather.multi: EU token: AxUFK3Q
2024-02-02 11:33:36.462 T:8372    debug <general>: weather.multi: EU sessionid: 3_cc-session_988ac64e-192f-42c0-ba12-c8a57116cebe
2024-02-02 11:33:36.462 T:8372    debug <general>: weather.multi: EU redirect https://www.yahoo.com/?guccounter&#x3D;2
2024-02-02 11:33:36.628 T:8372    debug <general>: weather.multi: cookies: <RequestsCookieJar[<Cookie A1=d=AQABBADFvGUCEBKXELDvyp-PkDtXq6NiPxkFEgABCAETvmXkZeUzb2UBAiAAAAcI_ ...
2024-02-02 11:33:37.061 T:8372    debug <general>: weather.multi: save cookie to settings: d=AQABBADFvGUCEBKXELDvyp-PkDtXq6NiPxkFEgABCAETvmXkZeUzb2UBAiAAAAcI_ ...
2024-02-02 11:33:37.061 T:8372    debug <general>: weather.multi: save crumb to settings: 6NwFhK2lbpX
2024-02-02 11:33:37.061 T:8372    debug <general>: weather.multi: save stamp to settings: 1706870017
2024-02-02 11:33:37.062 T:8372    debug <general>: weather.multi: weather location: 615702
2024-02-02 11:33:37.242 T:8372    debug <general>: weather.multi: yahoo forecast data: {'weathers': [{'woeid': 615702, 'unit': 'imperial', 'location': {'woeid': 615702, ....
2024-02-02 11:33:37.249 T:8372    debug <general>: weather.multi: available locations: 1
2024-02-02 11:33:37.249 T:8372    debug <general>: weather.multi: finished
2024-02-02 11:33:37.249 T:8372    debug <general>: CPythonInvoker(7, C:\Users\nic020\AppData\Roaming\Kodi\addons\weather.multi\default.py): script successfully run

Fix: weather.py
Replace::

88:     def get_ycreds(self):
89:         ysess = requests.Session()
90:         ycookie = ADDON.getSettingString('ycookie')
91:         ycrumb = ADDON.getSettingString('ycrumb')
92:         ystamp = ADDON.getSettingString('ystamp')
93:         log('cookie from settings: %s' % ycookie)
94:         log('crumb from settings: %s' % ycrumb)
95:         log('stamp from settings: %s' % ystamp)
96:         if ystamp == '' or (int(time.time()) - int(ystamp) > 31536000): # cookie expires after 1 year
97:             try:
98:                 for URL in CURL:
99:                     retry = 0
100:                    while (retry < 6) and (not self.MONITOR.abortRequested()):
101:                        response = ysess.get(URL, headers=HEADERS, timeout=10)
102:                        if response.status_code == 200:
103:                            break

By::

88:     def get_ycreds(self):
89:*        #ysess = requests.Session()
90:         ycookie = ADDON.getSettingString('ycookie')
91:         ycrumb = ADDON.getSettingString('ycrumb')
92:         ystamp = ADDON.getSettingString('ystamp')
93:         log('cookie from settings: %s' % ycookie)
94:         log('crumb from settings: %s' % ycrumb)
95:         log('stamp from settings: %s' % ystamp)
96:         if ystamp == '' or (int(time.time()) - int(ystamp) > 31536000): # cookie expires after 1 year
97:             try:
98:                 for URL in CURL:
99:*                    ysess = requests.Session()
100                     retry = 0
101:                    while (retry < 6) and (not self.MONITOR.abortRequested()):
102:                        response = ysess.get(URL, headers=HEADERS, timeout=10)
103:                        if response.status_code == 200:
104:                            break
[/quote]
Reply
thanx!
it indeed makes sense to restart the session with each url.

fixed in:
weather.multi-0.0.25.zip
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
(2024-02-04, 19:24)ronie Wrote: thanx!
it indeed makes sense to restart the session with each url.

fixed in:
weather.multi-0.0.25.zip

Works in Canada (Clean Install).

Thanks.
Reply
Thanks for update,
weather.multi-0.0.25.zip works in France.
Reply
(2024-02-05, 11:25)nic020 Wrote: Thanks for update,
weather.multi-0.0.25.zip works in France.
+1
works in Germany, too.👍🏻
Reply
0.0.25 works for me in Canada.  Thanks!
Reply
Thanks for the fix (version 0.0.25). The add-on stopped working a few weeks ago on my main Kodi device. It did not get any weather data anymore. I have the add-on running on several devices and strange enough, on some devices it still works while on others it doesn't. Re-installing the add-on from the Kodi repository did not solve the issue since that has only version 0.0.22. Today I found out that version 0.0.25 is available here and that fixed the issue.

May I suggest that you update the version on the Kodi repository so that less technical users can also keep enjoying the add-on while it could otherwise stop working for them at some point?
Reply
yup, it slipped my mind for a bit, but it's up for review now:
https://github.com/xbmc/repo-scripts/pull/2616
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
https://paste.kodi.tv/apegiconow.kodi

I can't get this to work. When I put my trailer away in Nov. 2023, it was on version .18, and worked. 

I start up and I get some crazy numbers like 2400F another is -32F. I've tried to update to .26, same result, tried .25 which is what the log results are... same thing.

Can't get it to work, what is the fix? 

Image

Image
Kodi: Nexus v20.5 | Skin Dev: Madnox Omega/Nexus: v20.01.02 | Madnox ForumRoot | Madnox Repov1.0.09 | Mr. V'sSource | Kodi Texture Tool (Takeover): v3.0.1 | Batch Texture Resize (Irfanview): Tutorial
Working On
: Replacing Embuary >> TMDB Helper || Start: 6/3/2024 End: God knows || Status Complete: Movies: 10% TV Shows: 0% Music: 0%
Reply
(2024-05-13, 00:13)kittmaster Wrote: https://paste.kodi.tv/apegiconow.kodi

I can't get this to work. When I put my trailer away in Nov. 2023, it was on version .18, and worked. 

I start up and I get some crazy numbers like 2400F another is -32F. I've tried to update to .26, same result, tried .25 which is what the log results are... same thing.

Can't get it to work, what is the fix? 

Image

Image
Do you see the same behavior using the Kodi default skin?
Reply
  • 1
  • 16
  • 17
  • 18(current)
  • 19
  • 20
  • 25

Logout Mark Read Team Forum Stats Members Help
Multi Weather0