IPython Generic Utilities

0.2.0 · deprecated · verified Thu Apr 09

ipython-genutils (version 0.2.0) is a collection of IPython-specific utility functions and modules that were extracted from the main IPython project. It served as a dependency for older IPython components and related projects during the Python 2 to 3 transition. It is considered vestigial, no longer actively developed, with its last release in 2017. New projects should avoid direct reliance on it.

Warnings

Install

Imports

Quickstart

This quickstart demonstrates importing and using a few common utilities from ipython-genutils, such as checking its version, verifying Python 3 compatibility, and retrieving the IPython directory path. It highlights that the library's functions are typically low-level or superseded.

from ipython_genutils.version import version_info
from ipython_genutils.py3compat import PY3
from ipython_genutils.path import get_ipython_dir

print(f"ipython-genutils version: {'.'.join(map(str, version_info))}")
print(f"Running on Python 3: {PY3}")

# Note: This path utility is largely internal to IPython/Jupyter now.
# For new projects, consider `jupyter_core.paths` or `pathlib`.
ipython_dir = get_ipython_dir()
print(f"Detected IPython directory (if configured): {ipython_dir}")

view raw JSON →