SatAgro / suntime

Simple sunset and sunrise time calculation python library.
GNU Lesser General Public License v3.0
110 stars 39 forks source link

Commit e9b1fa4 has breaking change #28

Closed timrprobocom closed 8 months ago

timrprobocom commented 8 months ago

Commit e9b1fa4 changed the source for get_sunrise_time and get_sunset_time so that the date parameter defaults to datetime.today(). Previously, it was the at_date parameter and defaulted to datetime.datetime.now().

Unfortunately, those are two different types. today() is a datettime.date, and now() is a datetime.datetime. The get_sun_timedelta method that both of these calls expects a datetime.datetime, resulting in a TypeError from utcoffset.

kstopa commented 8 months ago

Thanks for reporting. Solved in 1.3.2