{ } Raw JSON

bundles / IPython 9.17.0 / IPython / core / oinspect / getdoc

function

IPython.core.oinspect:getdoc

source: /dev/ipython/IPython/core/oinspect.py:192

Signature

def getdoc(obj) → str | None

Summary

Stable wrapper around inspect.getdoc.

Extended Summary

This can't crash because of attribute problems.

It also attempts to call a getdoc() method on the given object. This allows objects which provide their docstrings via non-standard mechanisms (like Pyro proxies) to still be inspected by ipython's ? system.

Aliases

  • IPython.core.oinspect.getdoc