Python
Python copied to clipboard
Ignore missing annotation in __init__ method by algorithms-keeper
Feature description
Please provide return type hint for the function: init. If the function does not return a value, please provide the type hint as: def function() -> None:
Adding -> None
have not sense, since this is a special method and it always returns None. Aslo this creates noise in code and even decreases readability when it's the reason for extra line breaks.
For example, this line fits without annotation and is split into 3 lines with it.
- def __init__(self, initial_block_size: int = 8, capacity_factor: float = 0.75) -> None:
+ def __init__(
+ self, initial_block_size: int = 8, capacity_factor: float = 0.75
+ ) -> None: