Remove another pylint ignore.

This commit is contained in:
Felix Fontein 2025-10-25 01:33:18 +02:00
parent 4a9ec3e307
commit 2ad818ed3b
6 changed files with 10 additions and 1 deletions

View File

@ -383,7 +383,6 @@ disable=raw-checker-failed,
consider-using-with, consider-using-with,
fixme, fixme,
import-error, # TODO figure out why pylint cannot find the module import-error, # TODO figure out why pylint cannot find the module
no-member,
no-name-in-module, # TODO figure out why pylint cannot find the module no-name-in-module, # TODO figure out why pylint cannot find the module
protected-access, protected-access,
redefined-outer-name, # needed for test fixtures redefined-outer-name, # needed for test fixtures

View File

@ -29,6 +29,7 @@ class ActionModule(ActionBase):
result = super().run(tmp, task_vars) result = super().run(tmp, task_vars)
del tmp # tmp no longer has any effect del tmp # tmp no longer has any effect
# pylint: disable-next=no-member
max_file_size_for_diff: int = C.MAX_FILE_SIZE_FOR_DIFF # type: ignore max_file_size_for_diff: int = C.MAX_FILE_SIZE_FOR_DIFF # type: ignore
self._task.args["_max_file_size_for_diff"] = max_file_size_for_diff self._task.args["_max_file_size_for_diff"] = max_file_size_for_diff

View File

@ -92,6 +92,7 @@ class Connection(ConnectionBase):
display.debug("in nsenter.exec_command()") display.debug("in nsenter.exec_command()")
# pylint: disable-next=no-member
def_executable: str | None = C.DEFAULT_EXECUTABLE # type: ignore[attr-defined] def_executable: str | None = C.DEFAULT_EXECUTABLE # type: ignore[attr-defined]
executable = def_executable.split()[0] if def_executable else None executable = def_executable.split()[0] if def_executable else None

View File

@ -652,6 +652,8 @@ class APIClient(_Session):
def get_adapter(self, url: str) -> BaseAdapter: def get_adapter(self, url: str) -> BaseAdapter:
try: try:
# pylint finds our Session stub instead of requests.Session:
# pylint: disable-next=no-member
return super().get_adapter(url) return super().get_adapter(url)
except _InvalidSchema as e: except _InvalidSchema as e:
if self._custom_adapter: if self._custom_adapter:

View File

@ -16,6 +16,8 @@ from .._import_helper import HTTPAdapter as _HTTPAdapter
class BaseHTTPAdapter(_HTTPAdapter): class BaseHTTPAdapter(_HTTPAdapter):
def close(self) -> None: def close(self) -> None:
# pylint finds our HTTPAdapter stub instead of requests.adapters.HTTPAdapter:
# pylint: disable-next=no-member
super().close() super().close()
if hasattr(self, "pools"): if hasattr(self, "pools"):
self.pools.clear() self.pools.clear()

View File

@ -58,7 +58,11 @@ class SSLHTTPAdapter(BaseHTTPAdapter):
We already take care of a normal poolmanager via init_poolmanager We already take care of a normal poolmanager via init_poolmanager
But we still need to take care of when there is a proxy poolmanager But we still need to take care of when there is a proxy poolmanager
Note that this method is no longer called for newer requests versions.
""" """
# pylint finds our HTTPAdapter stub instead of requests.adapters.HTTPAdapter:
# pylint: disable-next=no-member
conn = super().get_connection(*args, **kwargs) conn = super().get_connection(*args, **kwargs)
if ( if (
self.assert_hostname is not None self.assert_hostname is not None