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 serhiy.storchaka
Recipients ezyang, gvanrossum, levkivskyi, serhiy.storchaka, yselivanov
Date 2020-06-07.11:11:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1591528300.18.0.75542430356.issue40897@roundup.psfhosted.org>
In-reply-to
Content
It is not special for Generic, but happens with every type implementing __new__.

class A:
    def __new__(cls, a=1, *args, **kwargs):
        return object.__new__(cls)

class B(A):
    def __init__(self, b):
        pass

import inspect
print(inspect.signature(B))

The above example prints "(a=1, *args, **kwargs)" instead of "(b)".
History
Date User Action Args
2020-06-07 11:11:40serhiy.storchakasetrecipients: + serhiy.storchaka, gvanrossum, ezyang, yselivanov, levkivskyi
2020-06-07 11:11:40serhiy.storchakasetmessageid: <1591528300.18.0.75542430356.issue40897@roundup.psfhosted.org>
2020-06-07 11:11:40serhiy.storchakalinkissue40897 messages
2020-06-07 11:11:40serhiy.storchakacreate