functools.wraps and help()

Ulrich Eckhardt eckhardt at satorlaser.com
Wed Jun 2 08:20:35 EDT 2010


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?

Cheers!

Uli

-- 
Sator Laser GmbH
Geschäftsführer: Thorsten Föcking, Amtsgericht Hamburg HR B62 932




More information about the Python-list mailing list