-
-
Notifications
You must be signed in to change notification settings - Fork 409
Closed
Labels
Description
There was a suggestion in #38 that there be an option to make arguments keyword only. The suggested API was to have something like:
@attr.s
class A:
a = attr.ib()
b = attr.ib(init='kwonly')
# __init__ signature is:
# def __init__(self, a, *, b):
# passWould support for this be accepted? What about
@attr.s(kwonly=True)
class A:
a = attr.ib()
b = attr.ib()
# __init__ signature is:
# def __init__(self, *, a, b):
# passwhich may be nicer when subclassing?
Julian, cdunklau, vanife, RazerM, akhilman and 3 more