Become a MacRumors Supporter for $25/year with no ads, private forums, and more!
  • Did you order new AirTags? We've opened a dedicated AirTags forum.

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
Download: https://jonathanalland.com/dashboard-widgets.html

---

The Weather dashboard widget that ships with Mac OS X 10.4 – 10.14 broke in 2019, when the APIs it uses went offline. Luckily, the widget is all just editable Javascript code, so I rewrote a portion of the code to use the freely-accessible DarkSky and MapQuest APIs. Then I rewrote it again a few months later to use the Weatherbit API after Apple bought DarkSky, and again after getting frustrated with Weatherbit.

Previous versions of this widget required you to add your own API keys, but this is no longer necessary—just download and run! (Optional instructions for adding your own key are still included in the download; it's a good thing to set up if you have a few minutes to spare.)

This widget has been explicitly tested on 10.4 "Tiger", 10.6 "Snow Leopard", 10.9 "Mavericks", and 10.13 "High Sierra", but it should run on Tiger through Mojave. Please let me know if it does not.

Please also post if you encounter problems, notice something wrong, or just find something that could improved.
 
Last edited:

blikum

macrumors newbie
Dec 20, 2006
15
7
So far, so good. I made the background images transparent, I like the way it looks better. Once again thank you, thank you, thank you for all of the great work!

Screen Shot 2020-03-06 at 11.58.18 AM.jpg
 
Comment

Stephen.R

macrumors 68040
Nov 2, 2018
3,580
3,914
Thailand
It's been a while since I used a Dashboard widget, but might I suggest that the credentials required for the APIs could be entered on the 'back' of the widget, where you enter your preferred location?
 
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
It's been a while since I used a Dashboard widget, but might I suggest that the credentials required for the APIs could be entered on the 'back' of the widget, where you enter your preferred location?

I thought about it. The primary issue is that including a dialog for the API key inside the UI would pretty clearly violate DarkSky's rules. By contrast, I figure there's nothing to stop me from essentially distributing source code and providing instructions on how to finish it.

I also had some design concerns about putting too many fields on the back. I didn't want to ruin Apple's design, and as-is, I fretted for a long time about how to position the DarkSky logo.
 
Last edited:
  • Like
Reactions: gdwarner
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
Oh, phew, the widget isn't broken, you’re just having trouble obtaining a key.

Can you do as they say, and try generating a key again later? Maybe they're having a server blip.
 
Last edited:
  • Like
Reactions: gdwarner
Comment

blikum

macrumors newbie
Dec 20, 2006
15
7
Seems to work fine for me, but it doesn't seem to update. Mine still says 55 and sunny outside, but it's night time and in the 30's.
 
  • Like
Reactions: gdwarner
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
Seems to work fine for me, but it doesn't seem to update. Mine still says 55 and sunny outside, but it's night time and in the 30's.

That's not good! If you search for "Weather" in the console, do any Javascript errors come up?

What happens if you reload the widget? (make sure the widget is in focus and then cmd+r)
 
Comment

blikum

macrumors newbie
Dec 20, 2006
15
7
That's not good! If you search for "Weather" in the console, do any Javascript errors come up?

What happens if you reload the widget? (make sure the widget is in focus and then cmd+r)

No errors in console. When I refresh it does fetch the current conditions. It just seems like it's not refeshing on it's own.
 
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231

Can you try changing... anything possible about the machine you use to get the keys? Different browser, different device, different network, different physical location, etc.

You'll only ever have to do this once.

No errors in console. When I refresh it does fetch the current conditions. It just seems like it's not refeshing on it's own.

Okay, so presumably the function startFetchDataTimer() isn't running. You're in Wake Forest, NC, right? Going to see if I can reproduce the problem with that location.
 
Comment

blikum

macrumors newbie
Dec 20, 2006
15
7
Can you try changing... anything possible about the machine you use to get the keys? Different browser, different device, different network, different physical location, etc.

You'll only ever have to do this once.



Okay, so presumably the function startFetchDataTimer() isn't running. You're in Wake Forest, NC, right? Going to see if I can reproduce the problem with that location.

Yes, Wake Forest, NC. Thanks for helping.
 
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
Sigh, so now another user is also having issues getting a MapQuest key. Then I did a small amount of Googling, and it looks like lots of people are having this problem:


The issues appear to have (quite coincidentally) begun yesterday. Unfortunate, but presumably they'll fix it, let's just wait a bit.

If anyone knows of a better Geocoding API, please feel free to suggest it.
 
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
Yes, Wake Forest, NC. Thanks for helping.

Huh, that location is updating for me.

There's no reason this should do anything whatsoever, but just before I go crazy—can you try restoring the original weather widget without your transparency changes, to make sure the problem still happens?

Also, what OS are you running?
 
Last edited:
Comment

blikum

macrumors newbie
Dec 20, 2006
15
7
You know what? It's working for me too now. When I got up today, it was the same temp as last night, it didn't update. I'm on 10.10.5 I'll keep an eye on it and let you know what happens.
 
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
Because MapQuest is currently having problems, please send me a PM if you need a MapQuest key. Please note:
  1. Everyone who PM's me will get the same key. Please don't abuse the key by using it elsewhere. I will need to revoke the key if usage is too high.
  2. Regardless of usage, I will revoke this key as soon as I get hear that MapQuest has fixed their problems. At this time, you will need to go through the process to acquire and add your own key, or else the widget will stop working when you next change your location.
Thanks!

Sounds like this is fixed now!
 
Last edited:
Comment

Mr_Brightside_@

macrumors 68040
Sep 23, 2005
3,485
1,622
Toronto
I was having some issues with the widget on High Sierra, but a killall Dock in a Terminal cleared them up!
No issues with my MQ API key.
 
Comment

maxx1

macrumors newbie
Mar 7, 2020
3
1
Because MapQuest is currently having problems, please send me a PM if you need a MapQuest key. Please note:
  1. Everyone who PM's me will get the same key. Please don't abuse the key by using it elsewhere. I will need to revoke the key if usage is too high.
  2. Regardless of usage, I will revoke this key as soon as I get hear that MapQuest has fixed their problems. At this time, you will need to go through the process to acquire and add your own key, or else the widget will stop working when you next change your location.
Thanks!

Can you share the MapQuest key in a public message?
Thank you!
 
Comment

Erehy Dobon

Suspended
Feb 16, 2018
2,162
1,990
No service
As of 8am PDT today Sunday 8 March 2020, the Mapquest developer site was generating API keys normally.

I generated mine and edited the JS parser file per the instructions.

The widget works great here in California.

Thanks to Wowfunhappy for his hard work!
 
Comment

Wowfunhappy

macrumors 65816
Original poster
Mar 12, 2019
1,054
1,231
Thats for catalina too?

No, sorry! This is just a modified dashboard widget that will keep receiving new weather information now that the original servers have gone down. You still need to be running an operating system that has the dashboard, aka 10.4 – 10.14. In Catalina, the dashboard is completely gone! :(
 
Comment
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.