This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Antony.Lee
Recipients Antony.Lee
Date 2020-02-27.13:47:39
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1582811259.66.0.363702048971.issue39775@roundup.psfhosted.org>
In-reply-to
Content
https://bugs.python.org/issue36350 / https://github.com/python/cpython/pull/12412 changed Signature.parameters and BoundArguments.arguments to be plain dicts, not OrderedDicts (for Py3.9a4).  Even though I agree for BoundArguments.arguments (in fact I argued for this behavior in https://bugs.python.org/issue23080), I think Signature.parameters should remain OrderedDicts.  Otherwise, one would get

    >>> inspect.signature(lambda x, y: None).parameters == inspect.signature(lambda y, x: None).parameters
    True

which seems plain wrong (comparing the signature objects themselves still correctly return False because __eq__ explicitly considers parameter order, but one may e.g. want to compare parameters for equality while ignoring the return annotation).
History
Date User Action Args
2020-02-27 13:47:39Antony.Leesetrecipients: + Antony.Lee
2020-02-27 13:47:39Antony.Leesetmessageid: <1582811259.66.0.363702048971.issue39775@roundup.psfhosted.org>
2020-02-27 13:47:39Antony.Leelinkissue39775 messages
2020-02-27 13:47:39Antony.Leecreate