[RELEASE] DarkSky.net Weather Driver, no PWS Required

Updated and now seems to work

1 Like

Loving this feature - works perfectly. :+1: :+1: :+1:

2 Likes

Hi:
I installed the DarkSky driver a week ago and since then, have been experiencing occasional severe performance degradation. I checked the logs and see a lot of DarkSky.net Weather Driver WARNING: DarkSky weather api did not return data errors every five minutes for the past several hours. In the Preferences, I have the refresh time set to 3h for both day and night.

I tested my API key with a REST call and by manually refreshing the driver and all seems okay; any other debugging suggestions?

I'm getting that same error here. The virtual device I have that uses this driver hasn't been updated since 2:25 PM on 3/23/2020. Before this, it's been working flawlessly for months.

@Matthew any suggestions?

ETA: I checked the dashboard in my account with the Dark Sky API, and it shows no calls since 3/23.

@mrisher

Make sure you have updated to V1.3.8. I suspect you have a space in either your latitude or longitude coordinates on the hub. V1.3.8 will strip any spaces that cause an error in the Darksky data pull. If that does not fix your issue V1.3.8 will also show you the URL being sent to Darksky in the log, if there is an error, so you can further debug the issue.

I am on v1.3.8, and there were no spaces in the hub's coordinates.

I did find out what the problem was, though: "Override Hub's location coordinates" was turned off. Instead of picking up the Hub's lat/long, it was sending null,null in the URL. When I turned this on and entered lat/long, it started working fine again.

This started after I updated to v1.3.8, so I suspect something changed there?

That will do it. I will see if I can add some more informational log messages for this condition. Glad
you got it working.

EDIT: Wait. I misread your note. If Override was turn off, it should alway send the Hub's coordinates. If it is sending "null,null"when override is off and the Hub's coordinates are populated then I have something to fix. I'll look into this.

Yuppers, that's what it was doing. For now, turning override on got it working.

This is exactly what happened with me.

[UPDATED]
V1.3.9
03/26/2020

Changes:

  • Add more logic to prevent location coordinates being null or provide better logging when that cannot be prevented (hub's location coordinates are null).
1 Like

That seems to have done the trick, @Matthew. Thanks!

1 Like

To help keep this thread code focused.

My initial conversion of this driver to use Open WeatherMap was just published. It is very Alpha stages still so be cautious. I started a separate thread:

4 Likes

[UPDATED]
V1.4.0
04/19/2020

Changes:

  • Included code cleanup and optimizations that @nh.schottfam provided for the new OWM driver, that also work in this driver.
  • Improved log messaging when 'Extended Logging' is selected.
  • Various other code clean ups and bug fixes.
3 Likes

[UPDATED]
V1.4.1
04/20/2020

Changes:

  • Refactored much of the code.
  • Made the driver compatitible with the Hubitat Package Manager in the 'Integrations' category.
1 Like

uffff, I'm guessing if you dont already have this, then you arent getting it.

API

Our API service for existing customers is not changing today, but we will no longer accept new signups. The API will continue to function through the end of 2021.

As part of this transition, use of Dark Sky by Apple is subject to the Apple Privacy Policy, which can be found at apple.com/privacy.

Hi @Matthew - I can't get percentPrecip to work properly. On the device page, at the top under "current states", it reads 19 and never changes. This value of 19 is what gets set if I try to reference the parameter into a variable.

Direcrly below this in the weather summary text, it shows a value of 25...

In the data section at the bottom of the device page today it reads 25 (which matches the weather summary) and that value changes correctly on a daily basis after I poll the data again.

How to get the percentPrecip data to update properly into a variable instead of being 19 all the time?

First question is do you have that optional attrbribute turned on?


If you don't have it turned on, then it will not update in the 'Current States' or change for any dashboard or Rule Machine. If you do have it turned on, then I need to fix something. Let me know which, please.

Thanks. Will check it again...

Yes, both options are on. I've polled again and refreshed. Still no change to the current states value for PercentPrecip. It remains on 19.