I'm getting somewhat random results. Searching popular places gives me a single result, narrowing down the query or selecting a small town can get me additional results.
SilverAzide wrote: ↑June 24th, 2024, 11:23 pm
Open a PowerShell prompt and enter the following command, changing the XXXX to the name of a city/state/country. Post the results here.
I'm getting somewhat random results. Searching popular places gives me a single result, narrowing down the query or selecting a small town can get me additional results.
Something went wrong. (RM\Weather\Weather.ini)
RegExp matching error (-1) (RM\Weather\Weather.ini - [mWeatherParent])
No results found for that location. (RM\Weather\Weather.ini)
RegExp matching error (-1) (RM\Weather\Weather.ini - [mWeatherLocationParent])
Is this due to the API key changing again? I did try finding it from the page source on weather.com, but it was the same API key I already have. I only have location and current temperature in this skin.
I reduced this from Jelle Dekkers weather skin, JDWS-04:
Skin code:
sl23 wrote: ↑June 25th, 2024, 10:17 am
My weather skin has stopped working again, giving four errors:
Not sure at all this helps, but you may want to try restarting Rainmeter. I mean a complete restart: close it from the Notification Area icon and restart it from the Start Menu.
OK, I'm a bit mystified. If you search for "New York, NY", you only get a single search result whereas you used to get the maximum of 10. If you search for "New York", you get two results. If you search for "San Francisco" or "London" you get 10 results. I did a search for "Virginia" and I got all sorts of crazy results including some in Arabic, none of which were the US state.
Reading the OSM forums, it looks like OSM got hacked a few weeks ago (more like vandalism) and they are fixing the damage, so perhaps this has something to do with it. In any event, the API is at least working and returning results for me.
One caution I did notice while reviewing their API docs, is that their "search.php" URI is (has already been) deprecated and will stop working at some point. Most Rainmeter skins use this. The new URI simply drops the ".php" to conform to REST conventions.
Something went wrong. (RM\Weather\Weather.ini)
RegExp matching error (-1) (RM\Weather\Weather.ini - [mWeatherParent])
No results found for that location. (RM\Weather\Weather.ini)
RegExp matching error (-1) (RM\Weather\Weather.ini - [mWeatherLocationParent])
Is this due to the API key changing again?
I doubt it's related to the key, my guess is that it's the same Nominatim issue, since the 1st error is about the location. Try changing the UserAgent in mWeatherLocationParent based on the previous replies about it (the last one or two pages in this thread), or wait for jsmorley and SilverAzide to come up with a stable solution, if one exists.
Frankly, I don't really see why the said code needs to poll Nominatim every time weather is retrieved, polling just once when the skin is installed or when the user's location changed (something that happens very rarely anyway) or even on a manual click when really needed, followed by !WriteKeyValue the found coordinates to be used going forward should be more than enough. Apart from the update rates (which, although rare at every 15 minutes, are pointless unless you're in a high speed train all the time and incidentally you wouldn't care about the weather too much), if all weather skins behave like that, there's a lot of redundant calls that don't actually achieve anything other than confirming the same location retrieved the last time weather was retrieved.
balala wrote: ↑June 25th, 2024, 11:50 am
Not sure at all this helps, but you may want to try restarting Rainmeter. I mean a complete restart: close it from the Notification Area icon and restart it from the Start Menu.
Hi balala, thanks for replying.
Tbh, this has been like it now for a week or two. It's been restarted and so has my PC. This has had no effect.
Yincognito wrote: ↑June 25th, 2024, 12:02 pm
I doubt it's related to the key, my guess is that it's the same Nominatim issue, since the 1st error is about the location. Try changing the UserAgent in mWeatherLocationParent based on the previous replies about it (the last one or two pages in this thread), or wait for jsmorley and SilverAzide to come up with a stable solution, if one exists.
Frankly, I don't really see why the said code needs to poll Nominatim every time weather is retrieved, polling just once when the skin is installed or when the user's location changed (something that happens very rarely anyway) or even on a manual click when really needed, followed by !WriteKeyValue the found coordinates to be used going forward should be more than enough. Apart from the update rates (which, although rare at every 15 minutes, are pointless unless you're in a high speed train all the time and incidentally you wouldn't care about the weather too much), if all weather skins behave like that, there's a lot of redundant calls that don't actually achieve anything other than confirming the same location retrieved the last time weather was retrieved.
Thanks for the advice.
Re: Nominatum, can't you use google instead for location, or is it a developer preference?
Re: Update, it may surprise you that I have absolutely no idea how this skin works!
So I can set update to -1 then? Won't need to update throughout the day though? Is there anything else I can remove from the above code of mine just to slimline it? Or is it at it's minimum? When I say remove, I'm really talking about sections rather than surgically removing tiny bits of code. So just a quick skim should tell you if there is anything useless in it. Thanks