Python UtilsΒΆ

Python Utils β€” the fast, fully-typed stdlib helpers you keep rewriting PyPI version Supported Python versions CI status Coverage status

Python Utils is a collection of small, battle-tested functions and classes that make everyday Python patterns shorter, safer and faster. No sprawling framework, no heavy dependencies β€” just the helpers you find yourself rewriting in project after project, packaged once and typed to the hilt.

Highlights:

  • πŸͺΆ Zero-cost imports β€” PEP 562 lazy loading means import python_utils pulls in nothing until you touch a helper.

  • ⚑ Async-native β€” acount, abatcher and timeout/stall detectors for async for.

  • πŸ“¦ Smart containers β€” self-casting dicts, duplicate-proof lists, a sliceable deque.

  • πŸ”’ Forgiving converters β€” numbers out of messy strings, byte scaling, range remapping with Decimal precision.

  • 🎯 Fully typed & 100% covered β€” ships py.typed and passes mypy, basedpyright and pyrefly in strict mode.

New here? Start with πŸš€ Getting started.

Indices and tablesΒΆ