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)
| 198 | |
| 199 | @undoc |
| 200 | def 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 |
| 218 | def format_argspec(argspec): |
nothing calls this directly
no test coverage detected