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
Running the following code under Python 3.8.10 croniter-1.3.7
Note DST starts at 1 AM on 2022-03-12
from datetime import datetime
from croniter import croniter
from dateutil import tz
ny = tz.gettz('America/New_York')
d1=datetime(2022, 3, 12, 22, 0, 30, tzinfo=ny)
it = croniter("0 * * * *", d1)
for x in range(0, 10):
print(it.get_next(ret_type=datetime))
Running the following code under Python 3.8.10 croniter-1.3.7
Note DST starts at 1 AM on 2022-03-12
from datetime import datetime
from croniter import croniter
from dateutil import tz
ny = tz.gettz('America/New_York')
d1=datetime(2022, 3, 12, 22, 0, 30, tzinfo=ny)
it = croniter("0 * * * *", d1)
for x in range(0, 10):
print(it.get_next(ret_type=datetime))
I get:
2022-03-12 23:00:00-05:00
2022-03-13 00:00:00-05:00
2022-03-13 01:00:00-05:00
2022-03-13 01:00:00-05:00
2022-03-13 01:00:00-05:00
2022-03-13 01:00:00-05:00
2022-03-13 01:00:00-05:00
2022-03-13 01:00:00-05:00
03-13 01:00:00-05:00
2022-03-13 01:00:00-05:00
I expected:
2022-03-12 23:00:00-05:00
2022-03-13 00:00:00-05:00
2022-03-13 01:00:00-05:00
2022-03-13 03:00:00-04:00
2022-03-13 04:00:00-04:00
2022-03-13 05:00:00-04:00
2022-03-13 06:00:00-04:00
2022-03-13 07:00:00-04:00
2022-03-13 08:00:00-04:00
2022-03-13 09:00:00-04:00
The text was updated successfully, but these errors were encountered: