Yury Selivanov added the comment:
I think we should just fix the documentation, and update the code in example
with a proper check:
for param in sig.parameters.values():
if (param.name not in ba.arguments
and param.default is not param.empty):
ba.arguments[param.name] = param.default
I'm -1 on adding '_with_defaults' method, because usually you don't need this
(at least in my experience).
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue22998>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com