[Updated] Weather Underground Driver - New API

If you enable the logging, are you seeing this:

Which version of the driver are you using?

I've just posted a new version (V4.3.0) to github for this driver.

Sorry, I went out for my morning walk :slight_smile:
Yes, it was dark as it was about 6AM.
I grabbed the code from GitHub yesterday.
No, I am still seeing:
2019-04-24 09:03:56.156 am errorjava.lang.NullPointerException: Cannot execute null+1 on line 214 (pollSchedule)

dev:742019-04-24 09:03:56.131 am infostate.unit = e

I will grab the latest from GitHub and update, thanks.

With the latest driver, I am getting responses now.
Only other changes was that I set NewDayStarts to 12:00PM
Still no solarradiation but just checked my PWS and Solar is 0.0
Guess I'll be making a trip on the roof today.

Thanks again for your APP and quick support, I really appreciate it.

Current States

  • DriverAuthor : Cobra
  • DriverStatus : Current
  • DriverUpdate : N/A
  • DriverVersion : 4.3.0
  • UVHarm : High
  • chanceOfRain : 0
  • currentConditions : Generally clear. Highs 63 to 67ºF and lows 44 to 48ºF.
  • dewpoint : 49
  • elevation : 157
  • feelsLike : 63
  • forecastConditions : Partly cloudy. Highs 58 to 62ºF and lows 47 to 51ºF.
  • forecastHigh : 65
  • forecastLow : 46
  • humidity : 60
  • illuminance : No Data
  • latitude : 40.88063431
  • longitude : -73.25063324
  • moonPhase : Waning Gibbous
  • observation_time : 2019-04-24 09:12:00
  • pollsSinceReset : 2
  • precipType : rain
  • precip_rate : 0.00
  • precip_today : 0.00
  • pressure : 29.56
  • rainTomorrow : 0.0
  • solarradiation : No Data
  • stationID : KNYKINGS9
  • temperature : 63
  • weather : Sunny
  • wind : 5
  • windPhrase : Winds WNW at 10 to 20 mph.
  • windPhraseForecast : Winds NNW at 10 to 15 mph.
  • wind_degree : 321
  • wind_dir : WNW
1 Like

Thanks for your work on this, Cobra. Below is what I get from my Ambient Weather WS-2902A.
I wonder about the Nulls at the bottom.
Also, can you provide the icon names used and maybe some example icons?

Current States

  • DriverAuthor : Cobra
  • DriverStatus : Current
  • DriverUpdate : N/A
  • DriverVersion : 4.3.0
  • currentConditions : Generally clear. Low 51ºF.
  • currentIcon :
  • dewpoint : 52
  • elevation : 56
  • feelsLike : 64
  • forecastConditions : Partly cloudy. Highs 82 to 86ºF and lows 50 to 54ºF.
  • forecastIcon :
  • forecastLow : 51
  • humidity : 67
  • illuminance : No Data
  • latitude : 38.40999985
  • longitude : -121.34600067
  • moonPhase : Waxing Crescent
  • observation_time : 2019-05-07 20:21:42
  • pollsSinceReset : 2
  • precip_rate : 0.00
  • precip_today : 0.00
  • pressure : 30.02
  • solarradiation : No Data
  • stationID : KCAELKGR100
  • stationType : AMBWeatherV4.1.1
  • temperature : 64
  • wind : 1
  • windPhraseForecast : Winds SSW at 10 to 20 mph.
  • wind_degree : 209
  • wind_gust : 2
  • chanceOfRain : null
  • rainTomorrow : null
  • precipType : null
  • weather : null
  • windPhrase : null
  • forecastHigh : null
  • wind_dir : null
  • UVHarm : null

I'm guessing those "nulls" only update at certain times of day, as I have the same weather station as you and they are populated for me with this app, and have been for about a month now.

2 Likes

Hi there
The ‘nulls’ usually come about because the data ia not available at WU.
I get one or two occasionally, unfortunately there is not much I can do about it apart from marking them as ‘no data’ or something similar.
As @waynespringer79 says, they will probably come in at some point.

WU uses icon numbers rather than names.
You can find them here;

Hubitat/resources/wuIcons/png at master · CobraVmax/Hubitat · GitHub

Andy

1 Like

The ‘nulls’ went away after running overnight.
Thanks for the icons.

John

1 Like

Great! :slight_smile:

@Cobra, any thoughts of adding a 'Debug logging' switch so as to limit log messages once you know everything is working? I have done this with other drivers as described here: Turn off debugging? How?
I would make the modifications myself, but I would rather not modify your code if you are still actively developing.

Try turning off the ‘log all wu response data’ switch
This should disable most of the logging
I usually turn off the logging in my drivers automatically after 30 mins or so but have not implemented it in this driver.
I’ll look at adding it in the next release

search

This little icon in the top right of your screen is pretty magical

@Cobra I just started seeing this error today....any idea?

Looks like there may be an error at their end
I had the same error..

The request is timing out.

1 Like

I noticed I was running 4.2.0 and you had 4.3.0 out so I copied and pasted over the code but the device still shows wu1

Do I need to delete and recreate the device for it to update?

You should not normally have to delete and recreate the device.
please try updating the code again

New version 4.5.0

Andy

Same thing happened when pasting this code over the other, I refreshed the browser a couple times on the device page, still shown v4.2.0

But after clicking "save preferences" it then update to v4.5.0

Thanks for your help

I'm sorry, I should have mentioned...
whenever you update a driver, you should usually 'save preferences ' again :slight_smile:

I'm about to release another version (4.6.0) as I have streamlined the code somewhat

Andy

1 Like

Ok.. Version 4.6.0 Uploaded to github

Code optimisation...

  • Converted httpGet call to asynchttpGet - This should prevent hub waiting for the respose from WU before doing other things
  • Randomised the update check routine to reduce load on my update server.
  • Removed 'isStateChange: true' to reduce database load.
  • Changed debug logging to reduce logging spam
  • Auto turn off logging after 30 minutes
1 Like