Skip to main content

A string parsing toolset

Project description

STR-PARSE-TOOLS

This is a set of string parsing tools for python.

The following parsing elements are currently supported:

  • String of timedelta to timedelta
  • String of data size to float

Install

pip install strparsetools

Example

from strparsetools import string2timedelta, datasize2float

value = string2timedelta("1w2days1h1Minutes1s")
print(value)

> timedelta(days=9, hours=1, minutes=1, seconds=1)

# ------------------------------------------------

value = datasize2float("1G2Mb3k4")
print(value)

> float(1075842052.0)

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

strparsetools-0.2.0.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

strparsetools-0.2.0-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file strparsetools-0.2.0.tar.gz.

File metadata

  • Download URL: strparsetools-0.2.0.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.8.2

File hashes

Hashes for strparsetools-0.2.0.tar.gz
Algorithm Hash digest
SHA256 612153a78e513de07b18b9d5afb8adb89c93a442406e366453beb093f054800f
MD5 01baf3ec69eb9adac67ba8ddec0d5267
BLAKE2b-256 42952861c5458b5e8ed4f1b5a3fcfebdd0bf303130902e3dfcdaf40d859ce712

See more details on using hashes here.

File details

Details for the file strparsetools-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: strparsetools-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.8.2

File hashes

Hashes for strparsetools-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 75eeb09c1d11860e59b97e160440abd5c6ea17f36702856421183431421a1eb8
MD5 962b75a06ebed70075310498f63b49cf
BLAKE2b-256 9ab2c3ca9488abf5b95e394314a566f2d4b57e7c1f70061987966968c22c42da

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