You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Had a report (and simplified test code demonstrating so) that localizing the day of week as below doesn't always work properly (also applies to pirateweather):
auto
Monday
Tuesday
Wednesday
Thursday
America/Chicago
Tuesday
Wednesday
Thursday
Friday
I got the same output in Termux on an Android phone, but haven't tested on a "real computer" yet.
A timezone should likely be passed to datetime.fromtimestamp—presumably UTC, since AFAIK a Unix timestamp should always be in UTC—and then the value localized to the timezone at the coordinates.
The text was updated successfully, but these errors were encountered:
Had a report (and simplified test code demonstrating so) that localizing the day of week as below doesn't always work properly (also applies to pirateweather):
sopel-weather/sopel_modules/weather/providers/weather/openmeteo.py
Line 69 in 3506e90
On systems set to UTC, this seems to result in forecasts showing days off by one, e.g. M-Th when requested on Tu (expecting Tu-F in output).
Test code:
Output on a system set to 'Etc/UTC':
I got the same output in Termux on an Android phone, but haven't tested on a "real computer" yet.
A timezone should likely be passed to
datetime.fromtimestamp
—presumably UTC, since AFAIK a Unix timestamp should always be in UTC—and then the value localized to the timezone at the coordinates.The text was updated successfully, but these errors were encountered: