New submission from Chris Withers <ch...@withers.org>:
$ python Python 3.8.1 (v3.8.1:1b293b6006, Dec 18 2019, 14:08:53) [Clang 6.0 (clang-600.0.57)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from functools import partial >>> def foo(x, y, z, a=None): pass ... >>> p = partial(foo, 1, y=2) >>> from inspect import signature >>> signature(p).parameters.values() odict_values([<Parameter "y=2">, <Parameter "z">, <Parameter "a=None">]) That <Parameter "y=2"> shouldn't be in there: >>> p(2, y=3) Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: foo() got multiple values for argument 'y' ---------- messages: 362656 nosy: cjw296 priority: normal severity: normal status: open title: inspecting a partial with bound keywods gives incorrect signature _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue39753> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com