[Python-Dev] datetime.timedelta total_microseconds

Alexander Belopolsky alexander.belopolsky at gmail.com
Thu Feb 14 13:12:00 EST 2019


On Thu, Feb 14, 2019 at 9:07 AM Paul Ganssle <paul at ganssle.io> wrote:

> I don't think it's totally unreasonable to have other total_X() methods,
> where X would be days, hours, minutes and microseconds
>
I do.  I was against adding the total_seconds() method to begin with
because the same effect can be achieved with

delta / timedelta(seconds=1)

this is easily generalized to

delta / timedelta(X=1)

where X can be days, hours, minutes or microseconds.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20190214/29358ce4/attachment.html>


More information about the Python-Dev mailing list