I have a method that can raise some exceptions but all of those manually raise exception are caught with except clauses.
Imo, in this case it would be unnecessary to have the Raises: block in the docstring of the method.
MWE:
def test():
"""docstring."""
try:
raise RuntimeError('test')
except RuntimeError:
print('caught')
This raises an DCO050 in the docstring line although this RuntimeError will never be propagated to outside the method.
I have a method that can raise some exceptions but all of those manually raise exception are caught with except clauses.
Imo, in this case it would be unnecessary to have the Raises: block in the docstring of the method.
MWE:
This raises an DCO050 in the docstring line although this RuntimeError will never be propagated to outside the method.