Quantcast
Channel: Rainmeter Forums
Viewing all articles
Browse latest Browse all 1584

Help: Rainmeter Skins • Re: Weather Skins Not Working

$
0
0
Sorry, I couldn't recall where I asked about this, search didn't help me either.

My weather skin has stopped working again, giving four errors:

Code:

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:

Code:

[Rainmeter]Update=1000AccurateText=1DynamicWindowSize=1BackgroundMode=2SolidColor=0,0,0,1OnRefreshAction=[!UpdateMeter *] [!UpdateMeter *] [!Redraw]@Include=WeatherParser.inc[Metadata]Name=WeatherAuthor=sl23Version=2023-09-18License=Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)Information=Adapted from JDWS-04 by Jelle Dekkers (github.com/adriaanjelle)[Variables]Green=128,255,0White=255,255,255,200WeatherLocation=***** UK; Just enter your city's name or your address here or whatever. Anything should work here.; TIP: Check Rainmeter's About/log to see what location it got.========================================; STYLES========================================[Style]FontFace=Trebuchet MSFontColor=#White#FontSize=12AntiAlias=1DynamicVariables=1UpdateDivider=-1[sHighlight]MouseOverAction=[!SetOption #CURRENTSECTION# FontColor "#Green#"] [!UpdateMeter #CURRENTSECTION#] [!Redraw]MouseLeaveAction=[!SetOption #CURRENTSECTION# FontColor ""] [!UpdateMeter #CURRENTSECTION#] [!Redraw]========================================; WEATHER========================================[WeatherCurrentTemperature]Meter=StringMeterStyle=Style | sHighlightText=[mWeatherCurrentTemperature]°LeftMouseUpAction=[!Refresh]MiddleMouseUpAction=[!EditSkin]ToolTipIcon=InfoToolTipTitle=[mWeatherLocationCity]ToolTipText=L - Refresh#CRLF#M - EditX=2Y=0
WebParser code:

Code:

[Variables]Language=en-GBWeatherAPIKey=****2ea9dd2f4*****2ea9dd2f77****WeatherUnitsMetric=mWeatherUnitsImperial=eWeatherRegExpString=((?(?=null)null|".*"))WeatherRegExpNumber=((?(?=null)null|.*))WeatherSubstitute="^null$":"", '^"(.*)"$':"\1", "^\\1$":""WeatherUnits=Metric[mInternetConnectivity]Measure=PluginPlugin=SysInfoSysInfoType=INTERNET_CONNECTIVITYOnChangeAction=[!CommandMeasure mWeatherLocationParent Update]; ================================================[mWeatherLocationParent]Measure=WebParserURL=https://nominatim.openstreetmap.org/search?q=#WeatherLocation#&format=geocodejson&limit=1&addressdetails=1RegExp=(?siU)"features":\[{"type":"Feature","properties":{"geocoding":{.*,"label":"(.*)",.*,"admin":{"level\d+":"(.*)".*}}},"geometry":{"type": "Point","coordinates": \[(.*), (.*)\]}}\]UserAgent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.111 Safari/537.36UpdateRate=(60*15)FinishAction=[!UpdateMeasureGroup WeatherLocation] [!EnableMeasure mWeatherParent] [!UpdateMeasure mWeatherParent] [!Log "Location found: [mWeatherLocation]" Notice]OnConnectErrorAction=[!UpdateMeasureGroup WeatherLocation] [!EnableMeasure mWeatherParent] [!UpdateMeasure mWeatherParent] [!Log "Unable to connect to Nominatim." Error]OnRegExpErrorAction=[!UpdateMeasureGroup WeatherLocation] [!EnableMeasure mWeatherParent] [!UpdateMeasure mWeatherParent] [!Log "No results found for that location." Error]; ================================================[mWeatherLocation]Group=WeatherLocationMeasure=WebParserURL=[mWeatherLocationParent]StringIndex=1[mWeatherLocationCity]Group=WeatherLocationMeasure=WebParserURL=[mWeatherLocationParent]StringIndex=2Substitute="":"Earth"[mWeatherLocationLat]Group=WeatherLocationMeasure=WebParserURL=[mWeatherLocationParent]StringIndex=4Substitute="":"None"[mWeatherLocationLon]Group=WeatherLocationMeasure=WebParserURL=[mWeatherLocationParent]StringIndex=3Substitute="":"None"; ================================================[mWeatherParent]Group=ParentMeasure=WebParserURL=https://api.weather.com/v3/aggcommon/v3-wx-observations-current;v3-wx-forecast-daily-15day?format=json&geocode=[&mWeatherLocationLat],[&mWeatherLocationLon]&units=[#WeatherUnits[#WeatherUnits]]&language=[#Language]&apiKey=#WeatherAPIKey#RegExp=(?siU)"v3-wx-observations-current":.*{(.*)}.*"v3-wx-forecast-daily-15day":.*{(.*),"daypart":\[{(.*)}\]}UserAgent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.111 Safari/537.36UpdateRate=1FinishAction=[!EnableMeasureGroup Weather] [!UpdateMeasureGroup Weather] [!UpdateMeter *] [!UpdateMeter *] [!Redraw] [!Log "Finished parsing weather data." Notice]OnConnectErrorAction=[!EnableMeasureGroup Weather] [!UpdateMeasureGroup Weather] [!UpdateMeter *] [!UpdateMeter *] [!Redraw] [!Log "Unable to connect to Weather.com." Error]OnRegExpErrorAction=[!EnableMeasureGroup Weather] [!UpdateMeasureGroup Weather] [!UpdateMeter *] [!UpdateMeter *] [!Redraw] [!Log "Something went wrong." Error]DynamicVariables=1UpdateDivider=-1Disabled=1; ================================================[mWeatherCurrentTemperature]Group=WeatherMeasure=WebParserURL=[mWeatherParent]StringIndex=1RegExp=(?siU)"temperature":#WeatherRegExpNumber#[,}\]]StringIndex2=1RegExpSubstitute=1Substitute="#WeatherSubstitute#", "^$":"--"
Thanks :thumbup:

Statistics: Posted by sl23 — Today, 10:17 am



Viewing all articles
Browse latest Browse all 1584

Trending Articles