From 941e26dbe731e0150ea31ffb5c9d675bdb906e6e Mon Sep 17 00:00:00 2001 From: bkbilly Date: Sat, 1 Jun 2024 19:10:59 +0300 Subject: [PATCH] Add pylint exceptions inside the code --- .pre-commit-config.yaml | 2 +- lnxlink/__main__.py | 1 + lnxlink/modules/scripts/helpers.py | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b50db1e..0003a57 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -29,5 +29,5 @@ repos: - id: pylint args: [ "--generated-members=cv2.*,player.*,alsaaudio.Mixer", - "--disable=R0801,too-many-instance-attributes,line-too-long,eval-used,too-few-public-methods,broad-exception-caught,unused-argument,import-error,consider-using-with", + "--disable=duplicate-code,line-too-long,too-few-public-methods,broad-exception-caught,unused-argument,import-error", ] diff --git a/lnxlink/__main__.py b/lnxlink/__main__.py index 889b00c..e5de295 100755 --- a/lnxlink/__main__.py +++ b/lnxlink/__main__.py @@ -35,6 +35,7 @@ logger = logging.getLogger("lnxlink") +# pylint: disable=too-many-instance-attributes class LNXlink: """Start LNXlink service that loads all modules and connects to MQTT""" diff --git a/lnxlink/modules/scripts/helpers.py b/lnxlink/modules/scripts/helpers.py index eefcbc5..5c43c7c 100644 --- a/lnxlink/modules/scripts/helpers.py +++ b/lnxlink/modules/scripts/helpers.py @@ -7,6 +7,7 @@ logger = logging.getLogger("lnxlink") +# pylint: disable=consider-using-with def syscommand(command, ignore_errors=False, timeout=3, background=False): """Global subprocess command""" if isinstance(command, list):