naofireblade / homebridge-weather-plus

A comprehensive weather plugin for homebridge.
MIT License
315 stars 63 forks source link

Getting error "Could not retreive weather report with API 3.0, trying API 2.5 now" #290

Closed threeonparfive closed 5 months ago

threeonparfive commented 5 months ago

I've tried every city in my immediate area with the same result. I've also moved from version 3.3.3 to the latest beta and still no joy.

[4/13/2024, 6:20:50 AM] [homebridge-weather-plus] Launched child bridge with PID 12444 [4/13/2024, 6:20:51 AM] Registering platform 'homebridge-weather-plus.WeatherPlus' [4/13/2024, 6:20:51 AM] [homebridge-weather-plus] Loaded homebridge-weather-plus v3.3.4-beta.1 child bridge successfully [4/13/2024, 6:20:51 AM] Loaded 0 cached accessories from cachedAccessories.0E0F9E7A36CD. [4/13/2024, 6:20:51 AM] [homebridge-weather-plus] Adding station with weather service OpenWeatherMap named 'Kingsport' [4/13/2024, 6:20:51 AM] Homebridge v1.7.0 (HAP v0.11.1) (homebridge-weather-plus) is running on port 45437. [4/13/2024, 6:20:52 AM] [homebridge-weather-plus] Found coordinates for Fall Branch, US: { lat: 36.4181571, lon: -82.6237641 } [4/13/2024, 6:20:52 AM] [homebridge-weather-plus] Could not retreive weather report with API 3.0, trying API 2.5 now ...

dacarson commented 5 months ago

This is not an error. There are multiple APIs for OpenWeatherMap. The totally free version uses the 2.5 API. The plugin attempts to use the 3.0 API first and if that fails, then it falls back to the 2.5 API. It should be working. Can you tell me more about how it isn't working for you

threeonparfive commented 5 months ago

So I think I may have run in to a GUI bug that maybe left some garbage behind in the JSON causing a malfunction. Basically the issue I was seeing in the end was the occupancy sensor for wind speed, which I've had working for a long time, went away and wouldn't come back. This problem began when I was trying to change "location" in my OpenWeather config. I may have also been changing the wind threshold, can't remember. When I made these changes and restarted to take effect, the wind sensor never showed up and just kept showing the log snippet above. I tried every different location available in my area for OpenWeather and all ended up the same.

A few days later, I ended up getting my own weather station and needed to reconfigure the plugin to pull from Wunderground to use my PWS. I STILL wasn't getting the wind speed sensor! Through all of this, I even tried the latest beta for the plugin as I noticed it fixed a GUI bug for wind threshold but that didn't resolve it either.

I finally completely uninstalled the plugin, verified that no artifacts from it remained in the JSON, and started over again. Everything is working as it should again now. I suspect if I switched back to OpenWeather (perhaps requiring a full plugin rebuild again), it would work...but I have no reason/desire to try that.

I should have gone ahead and closed the issue but honestly forgot. Thanks for your time anyway and so sorry to have wasted it!

marhindev commented 5 months ago

Hello @dacarson, I had a similar issue: using API 2.5 but then the plugin just outputs the "error" message mentioned by the author here (which is just an info, I know), but then does not load any weather data, or at least I wasn't then able to add the plugin and bridge to my home (could not reach bridge). I checked also your issue comment on #282.

I can confirm that using the beta 3.3.4-beta.1 the plugin now successfully loads the data and the child bridge/device and weather data loads into my home.