Skip to content

Commit 76b8538

Browse files
Disable fixme for internal uses before we make it optional in #3512 (#6482)
1 parent e1769bd commit 76b8538

26 files changed

+25
-43
lines changed

pylint/checkers/base_checker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ def create_message_definition_from_tuple(
189189
warnings.filterwarnings("ignore", category=DeprecationWarning)
190190
if isinstance(self, (BaseTokenChecker, BaseRawFileChecker)):
191191
default_scope = WarningScope.LINE
192-
# TODO: 3.0: Remove deprecated if-statement # pylint: disable=fixme
192+
# TODO: 3.0: Remove deprecated if-statement
193193
elif implements(self, (IRawChecker, ITokenChecker)):
194194
warnings.warn( # pragma: no cover
195195
"Checkers should subclass BaseTokenChecker or BaseRawFileChecker"

pylint/checkers/classes/special_methods_checker.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,6 @@ def _is_iterator(node):
288288
if isinstance(node, astroid.bases.Generator):
289289
# Generators can be iterated.
290290
return True
291-
# pylint: disable-next=fixme
292291
# TODO: 2.14: Should be covered by https://github.com/PyCQA/astroid/pull/1475
293292
if isinstance(node, nodes.ComprehensionScope):
294293
# Comprehensions can be iterated.

pylint/checkers/typecheck.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -526,7 +526,6 @@ def _emit_no_member(
526526
def _determine_callable(
527527
callable_obj: nodes.NodeNG,
528528
) -> tuple[CallableObjects, int, str]:
529-
# pylint: disable=fixme
530529
# TODO: The typing of the second return variable is actually Literal[0,1]
531530
# We need typing on astroid.NodeNG.implicit_parameters for this
532531
# TODO: The typing of the third return variable can be narrowed to a Literal
@@ -1828,7 +1827,6 @@ def _check_unsupported_alternative_union_syntax(self, node: nodes.BinOp) -> None
18281827
self.add_message("unsupported-binary-operation", args=msg, node=node)
18291828
break
18301829

1831-
# pylint: disable-next=fixme
18321830
# TODO: This check was disabled (by adding the leading underscore)
18331831
# due to false positives several years ago - can we re-enable it?
18341832
# https://github.com/PyCQA/pylint/issues/6359
@@ -1837,7 +1835,6 @@ def _visit_binop(self, node: nodes.BinOp) -> None:
18371835
"""Detect TypeErrors for binary arithmetic operands."""
18381836
self._check_binop_errors(node)
18391837

1840-
# pylint: disable-next=fixme
18411838
# TODO: This check was disabled (by adding the leading underscore)
18421839
# due to false positives several years ago - can we re-enable it?
18431840
# https://github.com/PyCQA/pylint/issues/6359

pylint/checkers/utils.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1166,7 +1166,6 @@ def _supports_protocol(
11661166
if protocol_callback(value):
11671167
return True
11681168

1169-
# pylint: disable-next=fixme
11701169
# TODO: 2.14: Should be covered by https://github.com/PyCQA/astroid/pull/1475
11711170
if isinstance(value, nodes.ComprehensionScope):
11721171
return True

pylint/checkers/variables.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2200,7 +2200,6 @@ def _loopvar_name(self, node: astroid.Name) -> None:
22002200
scope = node.scope()
22012201
# FunctionDef subclasses Lambda due to a curious ontology. Check both.
22022202
# See https://github.com/PyCQA/astroid/issues/291
2203-
# pylint: disable-next=fixme
22042203
# TODO: Revisit when astroid 3.0 includes the change
22052204
if isinstance(scope, nodes.Lambda) and any(
22062205
asmt.scope().parent_of(scope) for asmt in astmts

pylint/config/arguments_manager.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,6 @@ def __init__(
8080
self._option_dicts: dict[str, OptionDict] = {}
8181
"""All option dictionaries that have been registered."""
8282

83-
# pylint: disable=fixme
8483
# TODO: 3.0: Remove deprecated attributes introduced to keep API
8584
# parity with optparse. Until '_maxlevel'
8685
with warnings.catch_warnings():
@@ -107,7 +106,7 @@ def config(self, value: argparse.Namespace) -> None:
107106

108107
@property
109108
def options_providers(self) -> list[ConfigProvider]:
110-
# TODO: 3.0: Remove deprecated attribute. # pylint: disable=fixme
109+
# TODO: 3.0: Remove deprecated attribute.
111110
warnings.warn(
112111
"options_providers has been deprecated. It will be removed in pylint 3.0.",
113112
DeprecationWarning,
@@ -629,7 +628,7 @@ def help(self, level: int | None = None) -> str:
629628

630629
def cb_set_provider_option(self, option, opt, value, parser): # pragma: no cover
631630
"""DEPRECATED: Optik callback for option setting."""
632-
# TODO: 3.0: Remove deprecated method. # pylint: disable=fixme
631+
# TODO: 3.0: Remove deprecated method.
633632
warnings.warn(
634633
"cb_set_provider_option has been deprecated. It will be removed in pylint 3.0.",
635634
DeprecationWarning,
@@ -647,7 +646,7 @@ def cb_set_provider_option(self, option, opt, value, parser): # pragma: no cove
647646

648647
def global_set_option(self, opt: str, value: Any) -> None: # pragma: no cover
649648
"""DEPRECATED: Set option on the correct option provider."""
650-
# TODO: 3.0: Remove deprecated method. # pylint: disable=fixme
649+
# TODO: 3.0: Remove deprecated method.
651650
warnings.warn(
652651
"global_set_option has been deprecated. You can use _arguments_manager.set_option "
653652
"or linter.set_option to set options on the global configuration object.",
@@ -734,7 +733,7 @@ def set_option(
734733
optdict: None | str | OptionDict = "default_value",
735734
) -> None:
736735
"""Set an option on the namespace object."""
737-
# TODO: 3.0: Remove deprecated arguments. # pylint: disable=fixme
736+
# TODO: 3.0: Remove deprecated arguments.
738737
if action != "default_value":
739738
warnings.warn(
740739
"The 'action' argument has been deprecated. You can use set_option "

pylint/config/arguments_provider.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class UnsupportedAction(Exception):
2020
"""Raised by set_option when it doesn't know what to do for an action."""
2121

2222
def __init__(self, *args: object) -> None:
23-
# TODO: 3.0: Remove deprecated exception # pylint: disable=fixme
23+
# TODO: 3.0: Remove deprecated exception
2424
warnings.warn(
2525
"UnsupportedAction has been deprecated and will be removed in pylint 3.0",
2626
DeprecationWarning,
@@ -50,7 +50,7 @@ def __init__(self, arguments_manager: _ArgumentsManager) -> None:
5050

5151
@property
5252
def level(self) -> int:
53-
# TODO: 3.0: Remove deprecated attribute # pylint: disable=fixme
53+
# TODO: 3.0: Remove deprecated attribute
5454
warnings.warn(
5555
"The level attribute has been deprecated. It was used to display the checker in the help or not,"
5656
" and everything is displayed in the help now. It will be removed in pylint 3.0.",
@@ -60,7 +60,7 @@ def level(self) -> int:
6060

6161
@level.setter
6262
def level(self, value: int) -> None:
63-
# TODO: 3.0: Remove deprecated attribute # pylint: disable=fixme
63+
# TODO: 3.0: Remove deprecated attribute
6464
warnings.warn(
6565
"Setting the level attribute has been deprecated. It was used to display the checker in the help or not,"
6666
" and everything is displayed in the help now. It will be removed in pylint 3.0.",
@@ -70,7 +70,7 @@ def level(self, value: int) -> None:
7070

7171
@property
7272
def config(self) -> argparse.Namespace:
73-
# TODO: 3.0: Remove deprecated attribute # pylint: disable=fixme
73+
# TODO: 3.0: Remove deprecated attribute
7474
warnings.warn(
7575
"The checker-specific config attribute has been deprecated. Please use "
7676
"'linter.config' to access the global configuration object.",
@@ -124,7 +124,7 @@ def option_value(self, opt: str) -> Any: # pragma: no cover
124124
# pylint: disable-next=unused-argument
125125
def set_option(self, optname, value, action=None, optdict=None): # pragma: no cover
126126
"""DEPRECATED: Method called to set an option (registered in the options list)."""
127-
# TODO: 3.0: Remove deprecated method. # pylint: disable=fixme
127+
# TODO: 3.0: Remove deprecated method.
128128
warnings.warn(
129129
"set_option has been deprecated. You can use _arguments_manager.set_option "
130130
"or linter.set_option to set options on the global configuration object.",

pylint/config/callback_actions.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,6 @@ def __call__(
261261
values: str | Sequence[Any] | None,
262262
option_string: str | None = "--generate-rcfile",
263263
) -> None:
264-
# pylint: disable-next=fixme
265264
# TODO: 2.14: Deprecate this after discussion about this removal has been completed.
266265
with warnings.catch_warnings():
267266
warnings.filterwarnings("ignore", category=DeprecationWarning)

pylint/config/configuration_mixin.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class ConfigurationMixIn(OptionsManagerMixIn, OptionsProviderMixIn):
1414
"""
1515

1616
def __init__(self, *args, **kwargs):
17-
# TODO: 3.0: Remove deprecated class # pylint: disable=fixme
17+
# TODO: 3.0: Remove deprecated class
1818
warnings.warn(
1919
"ConfigurationMixIn has been deprecated and will be removed in pylint 3.0",
2020
DeprecationWarning,

pylint/config/find_default_config_files.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,6 @@ def find_default_config_files() -> Iterator[Path]:
7878

7979
def find_pylintrc() -> str | None:
8080
"""Search the pylint rc file and return its path if it finds it, else return None."""
81-
# pylint: disable-next=fixme
8281
# TODO: 3.0: Remove deprecated function
8382
warnings.warn(
8483
"find_pylintrc and the PYLINTRC constant have been deprecated. "

0 commit comments

Comments
 (0)