Skip to main content

Duration parser.

Project description

Duration Parser

A simple python implementation of a duration parser.

Installation

pip install duration-parser

Usage

from duration_parser import parse

seconds = parse('1d2h')
seconds = parse('2 years 3 weeks')
seconds = parse('1.234min')
seconds = parse('1d, 2 weeks')

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

duration-parser-1.0.1.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

duration_parser-1.0.1-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file duration-parser-1.0.1.tar.gz.

File metadata

  • Download URL: duration-parser-1.0.1.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.11.1

File hashes

Hashes for duration-parser-1.0.1.tar.gz
Algorithm Hash digest
SHA256 2d5c465aeccd467f5c981fa78d69edd13459d6cc8ce3c751e12cbe40742163f3
MD5 7492fdee75a92c2f2cc56c064c84a9cd
BLAKE2b-256 6ebd49443f3b9b5bf10fabc5249b32f7a487f6029f14440bb56ea1a3b54fb405

See more details on using hashes here.

File details

Details for the file duration_parser-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for duration_parser-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 aecbb05af545f688f3f6277ab7720e538a8ab834e22c443e2a912f6c7ab6ec5c
MD5 18f9fd4660368bc21fe0c8fe9ed1e2e5
BLAKE2b-256 e95dd463fb48daf32d39159b36177a4e68b86bad350b7feb6715f1967272c4af

See more details on using hashes here.

Supported by

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