Skip to main content

datetime.timedelta replacement

Project description

Install

$ [sudo] pip install timedelta

Features

  • total seconds, minutes, hours, days, weeks, months, years

Examples

>>> from timedelta import Timedelta

>>> td = Timedelta(days=2, hours=2)

# init from datetime.timedelta
>>> td = Timedelta(datetime1 - datetime2)

total seconds, minutes, hours, days, weeks, months, years

>>> td = Timedelta(days=2, hours=2)
>>> td.total.seconds
180000
>>> td.total.minutes
3000
>>> td.total.hours
50
>>> td.total.days
2

Sources

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

timedelta-0.0.1.tar.gz (1.4 kB view details)

Uploaded Source

File details

Details for the file timedelta-0.0.1.tar.gz.

File metadata

  • Download URL: timedelta-0.0.1.tar.gz
  • Upload date:
  • Size: 1.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for timedelta-0.0.1.tar.gz
Algorithm Hash digest
SHA256 9f8ade4b930c0f58a91bd5f4ecabab83d5f630e302516213f543172d5b091638
MD5 27d68d2e6b539e5470c5ab3a454fa605
BLAKE2b-256 e2635a58e544e4960013e8297c71589c42e3c18526a2a5307e200092f214f9f0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page