[issue3250] datetime.time does not support arithmetic

George Boutsioukis report at bugs.python.org
Thu Jul 3 20:17:38 CEST 2008


George Boutsioukis <gboutsioukis at gmail.com> added the comment:

I have also come across this in the past. Although I sense that some
obscure reason might prevent time arithmetic from being included, here's
a patch to add time/timedelta addition and subtraction. It closely
follows the datetime arithmetic functions. To handle overflows, I
figured it should wrap around a 24-hour limit. The timezone stuff is
copied verbatim from the datetime functions, some finger-crossing applied.

----------
keywords: +patch
nosy: +gboutsioukis
Added file: http://bugs.python.org/file10806/datetime.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue3250>
_______________________________________


More information about the Python-bugs-list mailing list