# sizestr
[](https://pypi.org/project/sizestr)
[](https://liberapay.com/Zaczero/)
[](https://github.com/sponsors/Zaczero)
Simple and fast formatting of sizes for Python.
## Installation
The recommended installation method is through the PyPI package manager. The project is implemented in Rust and several pre-built binary wheels are available for Linux, macOS, and Windows, with support for both x64 and ARM architectures.
```sh
pip install sizestr
```
## Basic usage
```py
from sizestr import sizestr
sizestr(10000) # '9.77 KiB'
sizestr(-42) # '-42 B'
sizestr(float('inf')) # '(inf)'
```
Raw data
{
"_id": null,
"home_page": null,
"name": "sizestr",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": "file-size, human-readable, humanize, stringify",
"author": null,
"author_email": "Kamil Monicz <kamil@monicz.dev>",
"download_url": "https://files.pythonhosted.org/packages/09/a4/edcca24b8a024ea5a7eeb1f172cd528ea131c5382daf0493eae1448e0df3/sizestr-1.1.0.tar.gz",
"platform": null,
"description": "# sizestr\n\n[](https://pypi.org/project/sizestr)\n[](https://liberapay.com/Zaczero/)\n[](https://github.com/sponsors/Zaczero)\n\nSimple and fast formatting of sizes for Python.\n\n## Installation\n\nThe recommended installation method is through the PyPI package manager. The project is implemented in Rust and several pre-built binary wheels are available for Linux, macOS, and Windows, with support for both x64 and ARM architectures.\n\n```sh\npip install sizestr\n```\n\n## Basic usage\n\n```py\nfrom sizestr import sizestr\n\nsizestr(10000) # '9.77 KiB'\nsizestr(-42) # '-42 B'\nsizestr(float('inf')) # '(inf)'\n```\n\n",
"bugtrack_url": null,
"license": null,
"summary": "Simple and fast formatting of sizes for Python",
"version": "1.1.0",
"project_urls": {
"Issues": "https://github.com/Zaczero/sizestr/issues",
"Repository": "https://github.com/Zaczero/sizestr"
},
"split_keywords": [
"file-size",
" human-readable",
" humanize",
" stringify"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "1ecac1f390550840659bd0a92a1e67eb48b3533cb73386c43476851e85fa3c56",
"md5": "ad3e6cea3320839b2f2a0e96d0fce2a5",
"sha256": "de5a3c9273f079f5c05c043746bee873d37c57a2ef9e538a108ae6be55c3f8ae"
},
"downloads": -1,
"filename": "sizestr-1.1.0-cp39-abi3-macosx_10_12_x86_64.whl",
"has_sig": false,
"md5_digest": "ad3e6cea3320839b2f2a0e96d0fce2a5",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.9",
"size": 209960,
"upload_time": "2024-10-26T01:55:58",
"upload_time_iso_8601": "2024-10-26T01:55:58.827449Z",
"url": "https://files.pythonhosted.org/packages/1e/ca/c1f390550840659bd0a92a1e67eb48b3533cb73386c43476851e85fa3c56/sizestr-1.1.0-cp39-abi3-macosx_10_12_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "46ec3b932d560cad6bac7329fef07f16d37d585064f5d51c1d19a6b326fdd91f",
"md5": "1f6378391b44a9ec3886a4b76266da5a",
"sha256": "da34160c7bf38a8344157ebfe8032395f17e33b9ccaf01c222d41baf576a4069"
},
"downloads": -1,
"filename": "sizestr-1.1.0-cp39-abi3-macosx_11_0_arm64.whl",
"has_sig": false,
"md5_digest": "1f6378391b44a9ec3886a4b76266da5a",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.9",
"size": 205361,
"upload_time": "2024-10-26T01:55:59",
"upload_time_iso_8601": "2024-10-26T01:55:59.994158Z",
"url": "https://files.pythonhosted.org/packages/46/ec/3b932d560cad6bac7329fef07f16d37d585064f5d51c1d19a6b326fdd91f/sizestr-1.1.0-cp39-abi3-macosx_11_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "88f2c6b2c6793497d589802f458d7d2c470b1269b1ad59222afd795f2288c5f0",
"md5": "79db398718f40ae1ac02b6071a555229",
"sha256": "bb0e6ebdc7b7d382b05e2751664add8821f4313c68fb4bcf5eb67a75272e98bf"
},
"downloads": -1,
"filename": "sizestr-1.1.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl",
"has_sig": false,
"md5_digest": "79db398718f40ae1ac02b6071a555229",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.9",
"size": 213665,
"upload_time": "2024-10-26T01:56:02",
"upload_time_iso_8601": "2024-10-26T01:56:02.542273Z",
"url": "https://files.pythonhosted.org/packages/88/f2/c6b2c6793497d589802f458d7d2c470b1269b1ad59222afd795f2288c5f0/sizestr-1.1.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "a25f5a66add66ef25f3c07318b16b06dbbb4f790f3d555369a13295c135f7b0f",
"md5": "3b4de6b3530dac3ca1be85c3455d97b7",
"sha256": "adf6c3b3cff453e3bd3deed73e96f162d66a9a11cf3f9e30dab889642d60981b"
},
"downloads": -1,
"filename": "sizestr-1.1.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "3b4de6b3530dac3ca1be85c3455d97b7",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.9",
"size": 223028,
"upload_time": "2024-10-26T01:56:03",
"upload_time_iso_8601": "2024-10-26T01:56:03.978315Z",
"url": "https://files.pythonhosted.org/packages/a2/5f/5a66add66ef25f3c07318b16b06dbbb4f790f3d555369a13295c135f7b0f/sizestr-1.1.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "620a22bea949a3709f7eec517665ab39eb58d7bc2cc99d8577c112034de92ac8",
"md5": "4ca18cebab41533147da67976615ccd2",
"sha256": "7fe596bf68eee099abe12cc3976335d4c4dc82bc074feb9687eb653a03a6c39c"
},
"downloads": -1,
"filename": "sizestr-1.1.0-cp39-abi3-musllinux_1_2_aarch64.whl",
"has_sig": false,
"md5_digest": "4ca18cebab41533147da67976615ccd2",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.9",
"size": 420364,
"upload_time": "2024-10-26T01:56:05",
"upload_time_iso_8601": "2024-10-26T01:56:05.677963Z",
"url": "https://files.pythonhosted.org/packages/62/0a/22bea949a3709f7eec517665ab39eb58d7bc2cc99d8577c112034de92ac8/sizestr-1.1.0-cp39-abi3-musllinux_1_2_aarch64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "b7cd09f4ce1368712e87c18f5440d39d3812341857fc46b51820eea3eefbb040",
"md5": "f37cf595be808cd641161f89b7ec6894",
"sha256": "a9055643bdf509825d14a13f59d93d93b0b846c0110ddd85020c564339d404a0"
},
"downloads": -1,
"filename": "sizestr-1.1.0-cp39-abi3-musllinux_1_2_x86_64.whl",
"has_sig": false,
"md5_digest": "f37cf595be808cd641161f89b7ec6894",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.9",
"size": 403496,
"upload_time": "2024-10-26T01:56:06",
"upload_time_iso_8601": "2024-10-26T01:56:06.631500Z",
"url": "https://files.pythonhosted.org/packages/b7/cd/09f4ce1368712e87c18f5440d39d3812341857fc46b51820eea3eefbb040/sizestr-1.1.0-cp39-abi3-musllinux_1_2_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "84730b90c6cd16d6b05e2d39daac6f4f8b7faf4acc531d86db9e1013818523a2",
"md5": "ed01667f1bc43b8611f8aed374038e97",
"sha256": "50726adceb6c953c8828f674e0cf5d4abeeeb10b341705afc98007ab3c4c2db0"
},
"downloads": -1,
"filename": "sizestr-1.1.0-cp39-abi3-win_amd64.whl",
"has_sig": false,
"md5_digest": "ed01667f1bc43b8611f8aed374038e97",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.9",
"size": 110330,
"upload_time": "2024-10-26T01:56:08",
"upload_time_iso_8601": "2024-10-26T01:56:08.310634Z",
"url": "https://files.pythonhosted.org/packages/84/73/0b90c6cd16d6b05e2d39daac6f4f8b7faf4acc531d86db9e1013818523a2/sizestr-1.1.0-cp39-abi3-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "09a4edcca24b8a024ea5a7eeb1f172cd528ea131c5382daf0493eae1448e0df3",
"md5": "6de25311b0bfacc97b1c9885aebf167c",
"sha256": "cbad7109296414eaba97d7bd2f3ee7a7208d256c82914171a1a1d10f50c83a97"
},
"downloads": -1,
"filename": "sizestr-1.1.0.tar.gz",
"has_sig": false,
"md5_digest": "6de25311b0bfacc97b1c9885aebf167c",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 11837,
"upload_time": "2024-10-26T01:56:09",
"upload_time_iso_8601": "2024-10-26T01:56:09.523432Z",
"url": "https://files.pythonhosted.org/packages/09/a4/edcca24b8a024ea5a7eeb1f172cd528ea131c5382daf0493eae1448e0df3/sizestr-1.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-10-26 01:56:09",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "Zaczero",
"github_project": "sizestr",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "sizestr"
}