chrislit/abydos

View on GitHub

Showing 4,191 of 4,191 total issues

Too many statements (52/50)
Open

    def __init__(
Severity: Info
Found in abydos/distance/_token_distance.py by pylint

Used when a function or method has too many statements. You should then split it in smaller functions / methods.

Do not use len(SEQUENCE) without comparison to determine if a sequence is empty
Open

            if not len(self._soft_intersection_precalc):
Severity: Info
Found in abydos/distance/_token_distance.py by pylint

Used when Pylint detects that len(sequence) is being used without explicit comparison inside a condition to determine if a sequence is empty. Instead of coercing the length to a boolean, either rely on the fact that empty sequences are false or compare the length against a scalar.

Do not use len(SEQUENCE) without comparison to determine if a sequence is empty
Open

            if not len(self._soft_intersection_precalc):
Severity: Info
Found in abydos/distance/_token_distance.py by pylint

Used when Pylint detects that len(sequence) is being used without explicit comparison inside a condition to determine if a sequence is empty. Instead of coercing the length to a boolean, either rely on the fact that empty sequences are false or compare the length against a scalar.

Unnecessary elif after return
Open

        if self.params['alphabet'] is None:
Severity: Info
Found in abydos/distance/_token_distance.py by pylint

Used in order to highlight an unnecessary block of code following an if containing a return statement. As such, it will warn when it encounters an else following a chain of ifs, all of them containing a return statement.

String statement has no effect
Open

        """
Severity: Minor
Found in abydos/distance/_token_distance.py by pylint

Used when a string is used as a statement (which of course has no effect). This is a particular case of W0104 with its own message so you can easily disable it if you're using those strings as documentation, instead of comments.

Wrong hanging indentation before block (add 4 spaces).
Open

        tokenizer: Optional[_Tokenizer] = None,
Severity: Info
Found in abydos/distance/_gilbert.py by pylint

TODO tokenizer: Optional[_Tokenizer] = None, ^ |

Wrong hanging indentation before block (add 4 spaces).
Open

        src: str,

TODO src: str, ^ |

Wrong hanging indentation before block (add 4 spaces).
Open

        **kwargs: Any
Severity: Info
Found in abydos/distance/_kuhns_xi.py by pylint

TODO **kwargs: Any ^ |

Unnecessary parens after 'not' keyword
Open

                        if not (col_covered[col] | row_covered[row]):
Severity: Info
Found in abydos/distance/_token_distance.py by pylint

Used when a single item in parentheses follows an if, for, or other keyword.

Do not use len(SEQUENCE) without comparison to determine if a sequence is empty
Open

            if not len(self._soft_intersection_precalc):
Severity: Info
Found in abydos/distance/_token_distance.py by pylint

Used when Pylint detects that len(sequence) is being used without explicit comparison inside a condition to determine if a sequence is empty. Instead of coercing the length to a boolean, either rely on the fact that empty sequences are false or compare the length against a scalar.

Too many nested blocks (6/5)
Open

        while step < 4:
Severity: Info
Found in abydos/distance/_token_distance.py by pylint

Used when a function or a method has too many nested blocks. This makes the code less understandable and maintainable.

Variable name n doesn't conform to snake_case naming style
Open

        n = self._population_unique_card()
Severity: Info
Found in abydos/distance/_pattern.py by pylint

Used when the name doesn't conform to naming rules associated to its type (constant, variable, class...).

Wrong hanging indentation before block (add 4 spaces).
Open

        self,
Severity: Info
Found in abydos/distance/_gilbert.py by pylint

TODO self, ^ |

Variable name b doesn't conform to snake_case naming style
Open

        b = self._src_only_card()
Severity: Info
Found in abydos/distance/_gilbert.py by pylint

Used when the name doesn't conform to naming rules associated to its type (constant, variable, class...).

Wrong hanging indentation before block (add 4 spaces).
Open

        match_cost: float = 1,

TODO match_cost: float = 1, ^ |

Wrong hanging indentation before block (add 4 spaces).
Open

        **kwargs: Any

TODO **kwargs: Any ^ |

Wrong hanging indentation before block (add 4 spaces).
Open

        tokenizer: Optional[_Tokenizer] = None,

TODO tokenizer: Optional[_Tokenizer] = None, ^ |

Variable name d doesn't conform to snake_case naming style
Open

        d = self._total_complement_card()
Severity: Info
Found in abydos/distance/_kuhns_xi.py by pylint

Used when the name doesn't conform to naming rules associated to its type (constant, variable, class...).

Wrong hanging indentation before block (add 4 spaces).
Open

        tokenizer: Optional[_Tokenizer] = None,

TODO tokenizer: Optional[_Tokenizer] = None, ^ |

Parameters differ from overridden 'dist_abs' method
Open

    def dist_abs(self, src: str, tar: str, normalized: bool = False) -> float:
Severity: Minor
Found in abydos/distance/_eudex.py by pylint

Used when a method has a different number of arguments than in the implemented interface or in an overridden method.

Severity
Category
Status
Source
Language