pydocstyle
pydocstyle copied to clipboard
D107 (Missing docstring in __init__) conflicts with D418 (@overload shouldn't contain docstring)
You can't overload an init without failing one or the other of these rules currently:
class A:
@overload
def __init__(self):
# This fails D107: Missing docstring in __init__
pass
def __init__(self):
"""Docstring."""
pass
class B:
@overload
def __init__(self):
"""Docstring.""" # This fails D418: Function/ Method decorated with @overload shouldn't contain a docstring
pass
def __init__(self):
"""Docstring."""
pass
Duplicate of #525