This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author martin.panter
Recipients belopolsky, martin.panter, musically_ut, serhiy.storchaka
Date 2017-05-21.00:20:24
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I think the benefit of the repr being easier to understand outweighs the pain of breaking the old format. If the change is a problem, that might be mitigated by adding an entry to the “Porting to Python 3.7” documentation.

I don’t think my option of factoring the minus sign out to the front of the timedelta constructor was mentioned on Python-dev. The advantage is that it doesn’t mention problematic negative attribute values, and if you negate a timedelta, you still get the right attribute values:

>>> d
>>> -d
>>> (-d).seconds
Date User Action Args
2017-05-21 00:20:25martin.pantersetrecipients: + martin.panter, belopolsky, serhiy.storchaka, musically_ut
2017-05-21 00:20:25martin.pantersetmessageid: <>
2017-05-21 00:20:25martin.panterlinkissue30302 messages
2017-05-21 00:20:24martin.pantercreate