It is currently February 5th, 2023, 1:29 pm

Weatherbox

Weather skins
jpmaroco
Posts: 4
Joined: December 22nd, 2022, 7:33 pm

Re: Weatherbox

Post by jpmaroco »

Hi there,
December 2022, the weatherbox location is not working: Nothing foud. I guess the location API stopped working? Can you please take a look?
User avatar
eclectic-tech
Rainmeter Sage
Posts: 4947
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: Weatherbox

Post by eclectic-tech »

jpmaroco wrote: December 22nd, 2022, 7:46 pm Hi there,
December 2022, the weatherbox location is not working: Nothing foud. I guess the location API stopped working? Can you please take a look?
Working here, both auto and set by user...
wb.png
Have you tried looking up your weathercode and entering it manually?
You do not have the required permissions to view the files attached to this post.
User avatar
QuakeGuy
Posts: 33
Joined: February 3rd, 2020, 11:15 pm
Location: Germany

Re: Weatherbox

Post by QuakeGuy »

Hi jpmaroco,

i don't use the new latitude and longitude codes. My skin still works with weather.codes. I just tested cities in germany, united states and morocco. Very few german cities are not found because of German Umlaute. From there i know the 'Nothing found' message. But otherwise it should work.

What city you have problems with?
jpmaroco
Posts: 4
Joined: December 22nd, 2022, 7:33 pm

Re: Weatherbox

Post by jpmaroco »

Thanks QuakeGuy for the prompt reply.
I am at Pero Pinheiro:
Image
Image
Weather.com does find Pero Pinheiro:
PP6.png
You do not have the required permissions to view the files attached to this post.
Last edited by jpmaroco on December 23rd, 2022, 11:45 am, edited 1 time in total.
jpmaroco
Posts: 4
Joined: December 22nd, 2022, 7:33 pm

Re: Weatherbox

Post by jpmaroco »

eclectic-tech wrote: December 22nd, 2022, 8:08 pm Working here, both auto and set by user...
wb.png

Have you tried looking up your weathercode and entering it manually?
Indeed, nothing found for the IP retrieved city:
Image
ip.png
You do not have the required permissions to view the files attached to this post.
User avatar
xenium
Posts: 740
Joined: January 4th, 2018, 9:52 pm

Re: Weatherbox

Post by xenium »

jpmaroco wrote: December 22nd, 2022, 7:46 pm Hi there,
December 2022, the weatherbox location is not working: Nothing foud.
Go to Documents \ Rainmeter \ Skin \ WeatherBox \ @Resources open the Variables file and edit:

Location=3c75bbf9fb6c35b5bf9961f35069a2d957b95e8e2d9bd7ab6aee7ab5ac0e6e87
AutoLocation=0

Then refresh the skin

Edit:
After the website change in 2020, Weather.com uses a new format for locations code (see the long code at the end of the URL for your city).
The codes in the old format can still be used, but not all locations are displayed on the website https://weather.codes
User avatar
eclectic-tech
Rainmeter Sage
Posts: 4947
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: Weatherbox

Post by eclectic-tech »

xenium wrote: December 23rd, 2022, 11:59 am {clip}
After the website change in 2020, Weather.com uses a new format for locations code (see the long code at the end of the URL for your city).
The codes in the old format can still be used, but not all locations are displayed on the website https://weather.codes
Thanks for that info xenium :thumbup:
I haven't used weather.codes for quite a while and did not realize it had changed.
User avatar
QuakeGuy
Posts: 33
Joined: February 3rd, 2020, 11:15 pm
Location: Germany

Re: Weatherbox

Post by QuakeGuy »

Thx xenium. I didn't try using the long weather code with my skin. Glad it works. I can maybe shorten the displayed code, so the skin is not moved in its position.

Jpmaroco the long code is just at the end of Weather.com URL: https://weather.com/de-DE/wetter/heute/l/3c75bbf9fb6c35b5bf9961f35069a2d957b95e8e2d9bd7ab6aee7ab5ac0e6e87 Very small cities got no own old weather code, like Pero Pinhero. Unfortunately autolocation only works in conjunction with weather.codes. Maybe i will change/update my skin in the future...
jpmaroco
Posts: 4
Joined: December 22nd, 2022, 7:33 pm

Re: Weatherbox

Post by jpmaroco »

QuakeGuy wrote: December 23rd, 2022, 2:50 pm Thx xenium. I didn't try using the long weather code with my skin. Glad it works. I can maybe shorten the displayed code, so the skin is not moved in its position.

Jpmaroco the long code is just at the end of Weather.com URL: https://weather.com/de-DE/wetter/heute/l/3c75bbf9fb6c35b5bf9961f35069a2d957b95e8e2d9bd7ab6aee7ab5ac0e6e87 Very small cities got no own old weather code, like Pero Pinhero. Unfortunately autolocation only works in conjunction with weather.codes. Maybe i will change/update my skin in the future...
Thanks QuakeGuy for putting the time and effort on this.
I travel a bit, so I like the autolocation function on.
If I change the variables.inc file to

Code: Select all

;Location=POXX0320
;AutoLocation=1
Location=3c75bbf9fb6c35b5bf9961f35069a2d957b95e8e2d9bd7ab6aee7ab5ac0e6e87
AutoLocation=0
I get the local weather for a second or two and then it disappears and the "nothing found message" shows up again. It also displaces the skin like Xenium said.

Season greetings!
User avatar
eclectic-tech
Rainmeter Sage
Posts: 4947
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: Weatherbox

Post by eclectic-tech »

When AutoLocation=0, the skin will try to use your IP address to find your city weathercode value...
This will cause the skin to revert back to the old weathercode when updated and not find your city again.

To correct this, you could add a new variable to @Resources\variables.inc, let's call it BypassIP and set it to 1:
@Resources\variables.inc

Code: Select all

[Variables]
; Location=USNY0996
Location=3c75bbf9fb6c35b5bf9961f35069a2d957b95e8e2d9bd7ab6aee7ab5ac0e6e87
AutoLocation=0
BypassIP=1
Then add an additional test to the IfCondition in the [MeasureAutoLocation] section in Weathrebox.ini:
Weatherbox.ini

Code: Select all

[MeasureAutoLocation]
Measure=Calc
IfCondition=(#AutoLocation#=0)&&(#BypassIP#=1)
IfTrueAction=[!EnableMeasure MeasureWeather]
IfFalseAction=[!SetOption MeterSearchingIcon Text "B"][!SetOption MeterRetrievingWeather FontColor #Blue#][!SetOption MeterRetrievingWeather Text "searching ..."][!EnableMeasure MeasureLocationbyIP]
Save the files and refresh/load weatherbox.ini.

To use the skin's IP search, set BypassIP=0.