From 4de83b7ac28b33feb046373e1d220ea70570e7fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5vard=20Berland?= Date: Fri, 6 Jan 2023 15:30:15 +0100 Subject: [PATCH] Add pylint to ci Currently every current pylint issue is exempted. Excemptions (disables) in .pylintrc are to be removed one-by-one in upcoming PRs. --- .github/workflows/style.yml | 5 ++++ dev-requirements.txt | 1 + setup.cfg | 54 +++++++++++++++++++++++++++++++++++++ 3 files changed, 60 insertions(+) diff --git a/.github/workflows/style.yml b/.github/workflows/style.yml index 64908902b..3fa6d6776 100644 --- a/.github/workflows/style.yml +++ b/.github/workflows/style.yml @@ -27,6 +27,7 @@ jobs: - name: Install dependencies run: | + pip install . pip install -r dev-requirements.txt - name: Run black @@ -39,3 +40,7 @@ jobs: - name: Lint with flake8 run: | flake8 + + - name: pylint + run: | + pylint komodo tests setup.py diff --git a/dev-requirements.txt b/dev-requirements.txt index 3e3331fd9..371438bb2 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -1,4 +1,5 @@ black flake8 isort +pylint pytest diff --git a/setup.cfg b/setup.cfg index 2bcd70e39..627ac1e68 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,2 +1,56 @@ [flake8] max-line-length = 88 + +[pylint.message] +disable = bad-inline-option, + bare-except, + broad-except, + consider-using-dict-items, + consider-using-f-string, + consider-using-from-import, + consider-using-set-comprehension, + consider-using-sys-exit, + consider-using-with, + deprecated-pragma, + duplicate-code, + expression-not-assigned, + file-ignored, + fixme, + inconsistent-return-statements, + invalid-name, + keyword-arg-before-vararg, + line-too-long, + literal-comparison, + locally-disabled, + logging-not-lazy, + missing-class-docstring, + missing-function-docstring, + missing-module-docstring, + missing-timeout, + no-else-return, + protected-access, + raise-missing-from, + raw-checker-failed, + redefined-builtin, + redefined-outer-name, + suppressed-message, + too-few-public-methods, + too-many-arguments, + too-many-branches, + too-many-locals, + too-many-statements, + unidiomatic-typecheck, + unnecessary-comprehension, + unnecessary-lambda, + unnecessary-pass, + unspecified-encoding, + unused-argument, + unused-import, + unused-variable, + use-a-generator, + use-dict-literal, + use-implicit-booleaness-not-comparison, + use-symbolic-message-instead, + used-before-assignment, + useless-object-inheritance, + wrong-import-position, \ No newline at end of file