humanfriendly
Human friendly output for text interfaces using Python
Install
humanfriendly on PyPI
pip
pip install humanfriendlyuv
uv add humanfriendlypoetry
poetry add humanfriendlyPackage facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 3 — monotonic, pyreadline, pyreadline3 |
| Maintenance | abandoned — 1,791 days since the last release |
| First released | |
| Popularity | one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: humanfriendly-10.0-py2.py3-none-any.whl
About humanfriendly
from the package's own PyPI description — quoted content, verbatim
humanfriendly: Human friendly input/output in Python
.. image:: https://github.com/xolox/python-humanfriendly/actions/workflows/test.yml/badge.svg?branch=master :target: https://github.com/xolox/python-humanfriendly/actions
.. image:: https://codecov.io/gh/xolox/python-humanfriendly/branch/master/graph/badge.svg?token=jYaj4T74TU :target: https://codecov.io/gh/xolox/python-humanfriendly
The functions and classes in the humanfriendly package can be used to make
text interfaces more user friendly. Some example features:
-
Parsing and formatting numbers, file sizes, pathnames and timespans in simple, human friendly formats.
-
Easy to use timers for long running operations, with human friendly formatting of the resulting timespans.
-
Prompting the user to select a choice from a list of options by typing the option's number or a unique substring of the option.
-
Terminal interaction including text styling (
ANSI escape sequences_), user friendly rendering of usage messages and querying the terminal for its size.
The humanfriendly package is currently tested on Python 2.7, 3.5+ and PyPy
(2.7) on Linux...
AI interpretation — verify before relying
AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page
humanfriendly formats and parses numbers, file sizes, timespans, and terminal text in human-readable forms, plus provides interactive prompts and ANSI styling for command-line interfaces.
Low install friction with a pure-Python wheel, but the package is abandoned—no releases since 2021-09-17 (1791 days ago). Maintenance has stopped, so security patches and compatibility updates are unlikely.
MIT license is permissive; you may use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.
Usage
pip install humanfriendly
from humanfriendly import format_size, parse_size
num_bytes = parse_size("16G")
print(format_size(num_bytes))
Requires Python 2.7 or 3.5+; Windows ANSI support may need colorama package.
Verdict: humanfriendly is a mature, permissively licensed utility for text formatting in CLI applications with no known vulnerabilities, but it is abandoned and has not been maintained since 2021. Use it only if its existing feature set meets your needs and you are comfortable with no future updates.
Needs verification
- Whether runtime dependencies (monotonic, pyreadline, pyreadline3) are optional or required for all use cases.
- Current compatibility with Python 3.10+ given the package's age and lack of recent testing.
Similar packages
permissive · top 1,000 on PyPI
strictyamlpermissive · top 1,000 on PyPI
coloramapermissive · top 100 on PyPI
colorlogpermissive · top 1,000 on PyPI
Pygmentspermissive · top 100 on PyPI
wcwidthpermissive · top 1,000 on PyPI
cron-descriptorpermissive · top 1,000 on PyPI
termcolorpermissive · top 1,000 on PyPI
PyYAMLpermissive · top 100 on PyPI
isodurationpermissive · top 1,000 on PyPI