D
dlists.cad
Hi. I am looking for a way to check if some given set of (*args,
**kwds) conforms to the argument specification of a given function,
without calling that function.
For example, given the function foo:
def foo(a, b, c): pass
and some tuple args and some dict kwds, is there a way to tell if i
_could_ call foo(*args, **kwds) without getting an exception for those
arguments? I am hoping there is a way to do this without actually
writing out the argument logic python uses.
Thanks.
**kwds) conforms to the argument specification of a given function,
without calling that function.
For example, given the function foo:
def foo(a, b, c): pass
and some tuple args and some dict kwds, is there a way to tell if i
_could_ call foo(*args, **kwds) without getting an exception for those
arguments? I am hoping there is a way to do this without actually
writing out the argument logic python uses.
Thanks.