Registry / pymiscutils

pymiscutils

JSON →
library0.3.14pypypi✓ verified 24d ago

PyMiscUtils (installed via `pip install pymiscutils`) provides a collection of miscellaneous Python utilities, including context managers like `Timer` and `Suppressor`, a `NestedParser` for string parsing, and various helper classes for introspection, environment variables, and version management. The library is currently at version 0.3.14 and is under active development with frequent minor releases, though the API is subject to change.

pip install pymiscutils
INSTALL
IMPORT
SIG · PYMISCUTILS
P
pymiscutils
pythonv0.3.14
Install
16.9s avg
Import
Disk
285MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.3.14 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 246.1MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 16.9s · import 0.000s · 316MB
285MB installed
● package 285MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Timer
from pymiscutils import Timer
from miscutils import Timer

This example demonstrates using the `Timer` context manager to measure the execution time of a function. The `Timer` will print the elapsed time upon exiting the `with` block.

import time from miscutils.context_managers import Timer def long_running_task(): print("Starting a long task...") time.sleep(1.5) print("Task finished.") with Timer('My Task'): long_running_task()
Debug
Known issues
breakingThe library is explicitly stated as being under active development, and its API is subject to significant changes that may break existing code in future versions. Use with caution in production environments where API stability is critical.
fix
Regularly check the GitHub repository for updates and review release notes for breaking changes. Pin your dependency version in `requirements.txt` to mitigate unexpected issues: `pymiscutils==0.3.14`.
affects: 0.3.x (all versions)
gotchaThe PyPI package name is `pymiscutils`, but the actual top-level Python import package is `miscutils`. Attempting to `import pymiscutils` will result in an `ModuleNotFoundError`.
fix
Always use `import miscutils` or `from miscutils...` when importing components from this library after installation with `pip install pymiscutils`.
affects: All versions
gotchaMany useful classes and functions are nested within specific submodules (e.g., `miscutils.context_managers`, `miscutils.string_manipulation`, `miscutils.system`). Direct imports from `miscutils` for these specific components will often fail.
fix
Consult the GitHub README or source code to determine the correct submodule path for the specific utility you intend to import. For example, use `from miscutils.context_managers import Timer` instead of `from miscutils import Timer`.
affects: All versions
Upgrade
Version history
0.3.14latest on PyPI · released Feb 1, 2021
Audit
Dependencies
PythonrequiredRequired for execution.
Agent activity
5 hits · last 30 days
node
4
Resources
pymiscutils — pip install pymiscutils · libregistry