Skip to content

Commit d77adce

Browse files
DanielNoordPierre-Sassoulas
authored andcommitted
Remove some words from custom dictionary and update spelling
1 parent 5d1519b commit d77adce

26 files changed

+35
-57
lines changed

.pyenchant_pylint_custom_dict.txt

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,6 @@ async
2121
asynccontextmanager
2222
attr
2323
attrib
24-
autogenerated
25-
backend
26-
backticks
2724
BaseChecker
2825
basename
2926
behaviour
@@ -38,7 +35,6 @@ builtins
3835
bw
3936
callables
4037
cardinality
41-
cartesian
4238
cd
4339
cfg
4440
changelog
@@ -63,7 +59,6 @@ const
6359
Const
6460
contextlib
6561
contextmanager
66-
counterintuitive
6762
cpython
6863
CPython
6964
csv
@@ -128,7 +123,6 @@ graphname
128123
graphviz
129124
guido's
130125
gv
131-
hardcoded
132126
hashable
133127
hmac
134128
html
@@ -144,7 +138,6 @@ INI
144138
init
145139
initializer
146140
inlinevar
147-
instantiated
148141
instantiation
149142
isdir
150143
isfile
@@ -184,7 +177,6 @@ mapreduce
184177
maxsize
185178
maxsplit
186179
mcs
187-
mergeable
188180
mermaidjs
189181
metaclass
190182
metaclasses
@@ -201,7 +193,6 @@ msgs
201193
msg-template
202194
mult
203195
multiline
204-
multiprocess
205196
multiset
206197
multisets
207198
myattr
@@ -222,7 +213,6 @@ nonlocals
222213
num
223214
numpy
224215
ok
225-
onwards
226216
optdict
227217
optik
228218
optiondict
@@ -233,22 +223,16 @@ orelse
233223
os
234224
outputfile
235225
overridable
236-
parametrize
237-
parametrized
238226
params
239227
paren
240228
parens
241229
passthru
242230
png
243-
postprocessed
244-
postprocessing
245231
pragma
246232
pragma's
247233
pragmas
248234
pre
249235
preorder
250-
preprocess
251-
preprocessing
252236
proc
253237
py
254238
pyenchant
@@ -269,7 +253,6 @@ recognise
269253
recurse
270254
recurses
271255
redef
272-
redefinitions
273256
reportid
274257
rgx
275258
rheaders
@@ -283,7 +266,6 @@ runtime
283266
se
284267
sep
285268
setcomp
286-
shortcircuiting
287269
shortstrings
288270
singledispatch
289271
spammy
@@ -300,8 +282,6 @@ str
300282
stringified
301283
subclasses
302284
subdicts
303-
subdirectories
304-
subdirectory
305285
subgraphs
306286
sublists
307287
subparts
@@ -360,8 +340,6 @@ vcg's
360340
vectorisation
361341
virtualized
362342
wc
363-
whitespace
364-
whitespaces
365343
xfails
366344
xml
367345
xyz

pylint/checkers/base/basic_checker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -730,7 +730,7 @@ def _check_reversed(self, node):
730730
if isinstance(argument, (nodes.List, nodes.Tuple)):
731731
return
732732

733-
# dicts are reversible, but only from Python 3.8 onwards. Prior to
733+
# dicts are reversible, but only from Python 3.8 onward. Prior to
734734
# that, any class based on dict must explicitly provide a
735735
# __reversed__ method
736736
if not self._py38_plus and isinstance(argument, astroid.Instance):

pylint/checkers/base/name_checker/naming_style.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212

1313
class NamingStyle:
14-
"""It may seem counterintuitive that single naming style has multiple "accepted"
14+
"""It may seem counter-intuitive that single naming style has multiple "accepted"
1515
forms of regular expressions, but we need to special-case stuff like dunder names in method names.
1616
"""
1717

pylint/checkers/format.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@ def process_tokens(self, tokens: list[tokenize.TokenInfo]) -> None:
422422
elif tok_type not in (tokenize.COMMENT, tokenize.ENCODING):
423423
# This is the first concrete token following a NEWLINE, so it
424424
# must be the first token of the next program statement, or an
425-
# ENDMARKER; the "line" argument exposes the leading whitespace
425+
# ENDMARKER; the "line" argument exposes the leading white-space
426426
# for this statement; in the case of ENDMARKER, line is an empty
427427
# string, so will properly match the empty string with which the
428428
# "indents" stack was seeded
@@ -564,7 +564,7 @@ def _check_multi_statement_line(self, node, line):
564564
self._visited_lines[line] = 2
565565

566566
def check_line_ending(self, line: str, i: int) -> None:
567-
"""Check that the final newline is not missing and that there is no trailing whitespace."""
567+
"""Check that the final newline is not missing and that there is no trailing white-space."""
568568
if not line.endswith("\n"):
569569
self.add_message("missing-final-newline", line=i)
570570
return
@@ -636,7 +636,7 @@ def check_lines(self, lines: str, lineno: int) -> None:
636636
637637
Check lines have :
638638
- a final newline
639-
- no trailing whitespace
639+
- no trailing white-space
640640
- less than a maximum number of characters
641641
"""
642642
# we're first going to do a rough check whether any lines in this set

pylint/checkers/mapreduce_checker.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414

1515
class MapReduceMixin(metaclass=abc.ABCMeta):
16-
"""A mixin design to allow multiprocess/threaded runs of a Checker."""
16+
"""A mixin design to allow multi-process/threaded runs of a Checker."""
1717

1818
def __init__(self) -> None:
1919
warnings.warn(
@@ -24,7 +24,7 @@ def __init__(self) -> None:
2424

2525
@abc.abstractmethod
2626
def get_map_data(self) -> Any:
27-
"""Returns mergeable/reducible data that will be examined."""
27+
"""Returns merge-able/reducible data that will be examined."""
2828

2929
@abc.abstractmethod
3030
def reduce_map_data(self, linter: PyLinter, data: list[Any]) -> None:

pylint/checkers/misc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def process_tokens(self, tokens: list[tokenize.TokenInfo]) -> None:
138138
token_info for token_info in tokens if token_info.type == tokenize.COMMENT
139139
)
140140
for comment in comments:
141-
comment_text = comment.string[1:].lstrip() # trim '#' and whitespaces
141+
comment_text = comment.string[1:].lstrip() # trim '#' and white-spaces
142142

143143
# handle pylint disable clauses
144144
disable_option_match = OPTION_PO.search(comment_text)

pylint/checkers/refactoring/refactoring_checker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1296,7 +1296,7 @@ def _find_lower_upper_bounds(comparison_node, uses):
12961296

12971297
@staticmethod
12981298
def _apply_boolean_simplification_rules(operator, values):
1299-
"""Removes irrelevant values or returns shortcircuiting values.
1299+
"""Removes irrelevant values or returns short-circuiting values.
13001300
13011301
This function applies the following two rules:
13021302
1) an OR expression with True in it will always be true, and the

pylint/checkers/similar.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@
1111
(n is the minimum common lines option).
1212
The common hashes between both linesets are then looked for. If there are matches, then the match indices in both linesets are stored and associated
1313
with the corresponding couples (start line number/end line number) in both files.
14-
This association is then postprocessed to handle the case of successive matches. For example if the minimum common lines setting is set to four, then
14+
This association is then post-processed to handle the case of successive matches. For example if the minimum common lines setting is set to four, then
1515
the hashes are computed with four lines. If one of match indices couple (12, 34) is the successor of another one (11, 33) then it means that there are
1616
in fact five lines which are common.
17-
Once postprocessed the values of association table are the result looked for, i.e start and end lines numbers of common lines in both files.
17+
Once post-processed the values of association table are the result looked for, i.e start and end lines numbers of common lines in both files.
1818
"""
1919

2020
from __future__ import annotations
@@ -531,7 +531,7 @@ def _find_common(
531531
yield com
532532

533533
def _iter_sims(self) -> Generator[Commonality, None, None]:
534-
"""Iterate on similarities among all files, by making a cartesian
534+
"""Iterate on similarities among all files, by making a Cartesian
535535
product
536536
"""
537537
for idx, lineset in enumerate(self.linesets[:-1]):
@@ -562,7 +562,7 @@ def stripped_lines(
562562
ignore_signatures: bool,
563563
line_enabled_callback: Callable[[str, int], bool] | None = None,
564564
) -> list[LineSpecifs]:
565-
"""Return tuples of line/line number/line type with leading/trailing whitespace and any ignored code features removed.
565+
"""Return tuples of line/line number/line type with leading/trailing white-space and any ignored code features removed.
566566
567567
:param lines: a collection of lines
568568
:param ignore_comments: if true, any comment in the lines collection is removed from the result

pylint/checkers/spelling.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,9 +165,9 @@ def _next(self):
165165

166166

167167
def _strip_code_flanked_in_backticks(line: str) -> str:
168-
"""Alter line so code flanked in backticks is ignored.
168+
"""Alter line so code flanked in back-ticks is ignored.
169169
170-
Pyenchant automatically strips backticks when parsing tokens,
170+
Pyenchant automatically strips back-ticks when parsing tokens,
171171
so this cannot be done at the individual filter level.
172172
"""
173173

pylint/checkers/strings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -442,7 +442,7 @@ def _check_new_format(self, node, func):
442442
# Skip format nodes which don't have an explicit string on the
443443
# left side of the format operation.
444444
# We do this because our inference engine can't properly handle
445-
# redefinitions of the original string.
445+
# redefinition of the original string.
446446
# Note that there may not be any left side at all, if the format method
447447
# has been assigned to another variable. See issue 351. For example:
448448
#

0 commit comments

Comments
 (0)