Andreas Stührk <andy-pyt...@hammerhartes.de> added the comment: The correct call is more something like ``inspect.formatargspec(*inspect.getargspec(f))``, which should work for all (Python) functions in Python 3. In Python 2, tuple unpacking was represented using a nested list for the arguments:
>>> def f(x, (y, z)): pass ... >>> inspect.getargspec(f).args ['x', ['y', 'z']] It is impossible to get such a nested list from `getargspec()` now, but if you provide one, you execute the dead code path: >>> inspect.formatargspec(['x', ['y', 'z']]) TypeError: object of type 'map' has no len() ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue9683> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com