Showing 4,191 of 4,191 total issues
Wrong hanging indentation before block (add 4 spaces). Open
sim_func: Optional[Callable[[str, str], float]] = None,
- Read upRead up
- Exclude checks
TODO sim_func: Optional[Callable[[str, str], float]] = None, ^ |
Wrong hanging indentation before block (add 4 spaces). Open
**kwargs: Any
- Read upRead up
- Exclude checks
TODO **kwargs: Any ^ |
Variable name a
doesn't conform to snake_case naming style Open
a = self._intersection_card()
- Read upRead up
- Exclude checks
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
and (src[src_cur + i] == tar[tar_cur])
- Read upRead up
- Exclude checks
TODO and (src[srccur + i] == tar[tarcur]) ^ |
Wrong hanging indentation before block (add 4 spaces). Open
not (row_covered[row])
- Read upRead up
- Exclude checks
TODO not (row_covered[row]) ^ |
Do not use len(SEQUENCE)
without comparison to determine if a sequence is empty Open
if not len(self._soft_intersection_precalc):
- Read upRead up
- Exclude checks
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.
Consider using enumerate instead of iterating with range and len Open
for row in range(len(tar_only_tok)):
- Read upRead up
- Exclude checks
Emitted when code that iterates with range and len is encountered. Such code can be simplified by using the enumerate builtin.
Wrong hanging indentation before block (add 4 spaces). Open
alphabet: Optional[
- Read upRead up
- Exclude checks
TODO alphabet: Optional[ ^ |
Wrong hanging indentation before block (add 4 spaces). Open
intersection_type: str = 'crisp',
- Read upRead up
- Exclude checks
TODO intersection_type: str = 'crisp', ^ |
Unnecessary else
after return
Open
if not delta_ab:
- Read upRead up
- Exclude checks
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.
Wrong hanging indentation before block (add 4 spaces). Open
max_length: int = 8,
- Read upRead up
- Exclude checks
TODO max_length: int = 8, ^ |
Wrong hanging indentation before block (add 4 spaces). Open
**kwargs: Any
- Read upRead up
- Exclude checks
TODO **kwargs: Any ^ |
Unnecessary parens after 'not' keyword Open
if not (col_covered[col] | row_covered[row]):
- Read upRead up
- Exclude checks
Used when a single item in parentheses follows an if, for, or other keyword.
An attribute defined in abydos.distance._token_distance line 220 hides this method Open
def _intersection(self) -> TCounter[str]:
- Read upRead up
- Exclude checks
Used when a class defines a method which is hidden by an instance attribute from an ancestor class or set by some client code.
Wrong hanging indentation before block (add 4 spaces). Open
**kwargs: Any
- Read upRead up
- Exclude checks
TODO **kwargs: Any ^ |
Parameters differ from overridden 'dist' method Open
def dist(self, *args: Any, **kwargs: Any) -> NoReturn:
- Read upRead up
- Exclude checks
Used when a method has a different number of arguments than in the implemented interface or in an overridden method.
Too many branches (14/12) Open
def dist_abs(self, src: str, tar: str) -> float:
- Read upRead up
- Exclude checks
Used when a function or method has too many branches, making it hard to follow.
Wrong hanging indentation before block (add 4 spaces). Open
(src_cur + i < src_len) or (tar_cur + i < tar_len)
- Read upRead up
- Exclude checks
TODO (srccur + i < srclen) or (tarcur + i < tarlen) ^ |
Wrong hanging indentation before block (add 4 spaces). Open
self.params['tokenizer'], (QGrams, QSkipgrams)
- Read upRead up
- Exclude checks
TODO self.params['tokenizer'], (QGrams, QSkipgrams) ^ |
Wrong hanging indentation before block (add 4 spaces). Open
and self.params['normalizer'] in self._norm_dict
- Read upRead up
- Exclude checks
TODO and self.params['normalizer'] in self.normdict ^ |