Skip to content

Commit

Permalink
Removed old pylint pragmas
Browse files Browse the repository at this point in the history
  • Loading branch information
AWhetter committed Jul 8, 2023
1 parent a22ae92 commit 92437c9
Show file tree
Hide file tree
Showing 9 changed files with 10 additions and 28 deletions.
15 changes: 0 additions & 15 deletions .pre-commit-config.yaml

This file was deleted.

4 changes: 2 additions & 2 deletions autoapi/directives.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from .mappers.python.objects import PythonFunction


class AutoapiSummary(Autosummary): # pylint: disable=too-few-public-methods
class AutoapiSummary(Autosummary):
"""A version of autosummary that uses static analysis."""

def get_items(self, names):
Expand Down Expand Up @@ -40,7 +40,7 @@ def get_items(self, names):
return items


class NestedParse(Directive): # pylint: disable=too-few-public-methods
class NestedParse(Directive):

"""Nested parsing to remove the first heading of included rST
Expand Down
4 changes: 1 addition & 3 deletions autoapi/documenters.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
PythonException,
)

# pylint: disable=attribute-defined-outside-init,unused-argument


class AutoapiDocumenter(autodoc.Documenter):
def get_attr(self, obj, name, *defargs):
Expand Down Expand Up @@ -82,7 +80,7 @@ def get_object_members(self, want_all):
return False, children


class _AutoapiDocstringSignatureMixin: # pylint: disable=too-few-public-methods
class _AutoapiDocstringSignatureMixin:
def format_signature(self, **kwargs):
# Set "manual" attributes at the last possible moment.
# This is to let a manual entry or docstring searching happen first,
Expand Down
4 changes: 2 additions & 2 deletions autoapi/extension.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def _normalise_autoapi_dirs(autoapi_dirs, srcdir):
return normalised_dirs


def run_autoapi(app): # pylint: disable=too-many-branches
def run_autoapi(app):
"""Load AutoAPI data from the filesystem."""
if not app.config.autoapi_dirs:
raise ExtensionError("You must configure an autoapi_dirs setting")
Expand Down Expand Up @@ -143,7 +143,7 @@ def build_finished(app, exception):
shutil.rmtree(normalized_root)


def source_read(app, docname, source): # pylint: disable=unused-argument
def source_read(app, docname, source):
# temp_data is cleared after each source file has been processed,
# so populate the annotations at the beginning of every file read.
app.env.temp_data["annotations"] = getattr(app.env, "autoapi_annotations", {})
Expand Down
2 changes: 1 addition & 1 deletion autoapi/inheritance_diagrams.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def _import_classes(class_names, currmodule):

def _class_info(
self, classes, show_builtins, private_bases, parts, aliases, top_classes
): # pylint: disable=too-many-arguments
):
all_classes = {}

def recurse(cls):
Expand Down
1 change: 0 additions & 1 deletion autoapi/mappers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,6 @@ def load(self, patterns, dirs, ignore=None):

@staticmethod
def find_files(patterns, dirs, ignore):
# pylint: disable=too-many-nested-blocks
if not ignore:
ignore = []

Expand Down
5 changes: 2 additions & 3 deletions autoapi/mappers/python/astroid_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
import astroid
import astroid.nodes

# Disable until pylint uses astroid 2.7
import astroid.nodes.node_classes # pylint: disable=no-name-in-module
import astroid.nodes.node_classes
import sphinx.util.logging

_LOGGER = sphinx.util.logging.getLogger(__name__)
Expand Down Expand Up @@ -473,7 +472,7 @@ def _iter_args(args, annotations, defaults):
yield (name, format_annotation(annotation), default)


def get_args_info(args_node): # pylint: disable=too-many-branches,too-many-statements
def get_args_info(args_node):
result = []
positional_only_defaults = []
positional_or_keyword_defaults = args_node.defaults
Expand Down
2 changes: 1 addition & 1 deletion autoapi/mappers/python/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ def parse_classdef(self, node, data=None):
def parse_asyncfunctiondef(self, node):
return self.parse_functiondef(node)

def parse_functiondef(self, node): # pylint: disable=too-many-branches
def parse_functiondef(self, node):
if astroid_utils.is_decorated_with_property_setter(node):
return []

Expand Down
1 change: 1 addition & 0 deletions docs/changes/+5819ffe5.misc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Removed old pylint pragmas

0 comments on commit 92437c9

Please sign in to comment.