functools.wraps and help()

Michele Simionato michele.simionato at gmail.com
Wed Jun 2 08:47:40 EDT 2010


On Jun 2, 2:20 pm, Ulrich Eckhardt <eckha... at satorlaser.com> wrote:
> Hi!
>
> When I use help() on a function, it displays the arguments of the function,
> along with the docstring. However, when wrapping the function using
> functools.wraps it only displays the arguments that the (internal) wrapper
> function takes, which is typically "*args, **kwargs", which isn't very
> useful.
>
> Any suggestions how to fix that? Is that even a bug or a systematic
> limitation? In case of the latter, should the documentation for
> functools.wraps mention it?

See http://pypi.python.org/pypi/decorator



More information about the Python-list mailing list