MCPcopy Create free account
hub / github.com/ipython/ipython / getargspec

Function getargspec

IPython/core/oinspect.py:200–215  ·  view source on GitHub ↗

Wrapper around :func:`inspect.getfullargspec` In addition to functions and methods, this can also handle objects with a ``__call__`` attribute. DEPRECATED: Deprecated since 7.10. Do not use, will be removed.

(obj)

Source from the content-addressed store, hash-verified

198
199@undoc
200def getargspec(obj):
201 """Wrapper around :func:`inspect.getfullargspec`
202
203 In addition to functions and methods, this can also handle objects with a
204 ``__call__`` attribute.
205
206 DEPRECATED: Deprecated since 7.10. Do not use, will be removed.
207 """
208
209 warnings.warn('`getargspec` function is deprecated as of IPython 7.10'
210 'and will be removed in future versions.', DeprecationWarning, stacklevel=2)
211
212 if safe_hasattr(obj, '__call__') and not is_simple_callable(obj):
213 obj = obj.__call__
214
215 return inspect.getfullargspec(obj)
216
217@undoc
218def format_argspec(argspec):

Callers

nothing calls this directly

Calls 3

safe_hasattrFunction · 0.90
is_simple_callableFunction · 0.85
warnMethod · 0.80

Tested by

no test coverage detected