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
{{ message }}
Repository navigation
Adding a timedelta to an aware datetime object not resulting in the correct time being calculated #123487
Activity
rruuaanng commentedon Sep 8, 2024
I'm sorry that I don't have a mac, but I will test it on win.
zuo commentedon Oct 3, 2024
The described behavior may be non-intuitive for some people (including me, at least at first sight), but it is intended and documented (see: Supported operations below https://docs.python.org/3/library/datetime.html#datetime.datetime.fold).
See also: https://blog.ganssle.io/articles/2018/02/aware-datetime-arithmetic.html
StanFromIreland commentedon Mar 14, 2025
This is the documented behavior as mentioned above. This issue should be closed.
Duplicate where improvement of docs is under consideration: #116111