dshanske / simple-location

Adds Basic Location Support to Wordpress
https://wordpress.org/plugins/simple-location
Other
29 stars 14 forks source link

Bug in the Weather Widget display of sunrise/sunset and moonrise/moonset #201

Open chrisaldrich opened 4 years ago

chrisaldrich commented 4 years ago

I’m noticing that the sunrise/sunset and moonrise/moonset details in the Weather Widget are “off”. It currently displays the following:

Sunrise: 10:40 pm Sunset: 10:47 am Moonrise: 10:54 am Moonset: 10:32 pm

Sunrise should be 7:13 AM (roughly for today) though 6:13 AM for tomorrow after Daylight Saving Time changes tonight. Moonrise today should be roughly 5:52 pm and moonset at 6:14 am.

Manually changing the lat/long in the Weather widget doesn’t seem to fix it. I also get the same numbers if there isn’t lat/long in the widget but have them in the user profile in the location section.

I’m using OpenWeatherMap as the provider, and I notice I’m getting two different readings for the sunrise/set & moonrise/set depending on whether I’m using the User Last Seen Widget or the Weather widget, so maybe the issue is hiding in the difference between calculations of one versus the other? The weather widget is the one giving the incorrect readings.

(Originally published at: https://boffosocko.com/?p=55780233)