abydos/corpus/_unigram_corpus.py
Unnecessary else
after return
Open
Open
if term in self.corpus:
- 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.
Unused argument 'args' Open
Open
def _dd_default(*args: Any) -> Tuple[int, int]:
- Read upRead up
- Exclude checks
Used when a function or method argument is not used.
Unused variable 'count' Open
Open
count, term_doc_count = self.corpus[term]
- Read upRead up
- Exclude checks
Used when a variable is defined but not used.
Wrong hanging indentation before block (add 4 spaces). Open
Open
corpus_text: str = '',
- Read upRead up
- Exclude checks
TODO corpus_text: str = '', ^ |
Wrong hanging indentation before block (add 4 spaces). Open
Open
word_tokenizer: Optional[_Tokenizer] = None,
- Read upRead up
- Exclude checks
TODO wordtokenizer: Optional[Tokenizer] = None, ^ |
Wrong hanging indentation before block (add 4 spaces). Open
Open
self,
- Read upRead up
- Exclude checks
TODO self, ^ |
Wrong hanging indentation before block (add 4 spaces). Open
Open
word_transform: Optional[Callable[[str], str]] = None,
- Read upRead up
- Exclude checks
TODO word_transform: Optional[Callable[[str], str]] = None, ^ |
Wrong hanging indentation before block (add 4 spaces). Open
Open
documents: int = 0,
- Read upRead up
- Exclude checks
TODO documents: int = 0, ^ |
Variable name n
doesn't conform to snake_case naming style Open
Open
n = tokens[tok] * count
- Read upRead up
- Exclude checks
Used when the name doesn't conform to naming rules associated to its type (constant, variable, class...).