From f3faf1d13e344ba85904da2650b4ead0bdcafb66 Mon Sep 17 00:00:00 2001 From: Sudhansu <13695177+the-lazy-learner@users.noreply.github.com> Date: Fri, 4 Nov 2022 22:36:53 +0530 Subject: [PATCH 1/2] Modify precommit config yaml and change name of typing step to Typing + pylint. --- .github/workflows/code-checks.yml | 2 +- .pre-commit-config.yaml | 2 ++ environment.yml | 1 + pyproject.toml | 3 +++ requirements-dev.txt | 1 + 5 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/code-checks.yml b/.github/workflows/code-checks.yml index 738263369409c..583619826265c 100644 --- a/.github/workflows/code-checks.yml +++ b/.github/workflows/code-checks.yml @@ -86,7 +86,7 @@ jobs: echo "PYTHONPATH=$PYTHONPATH" >> $GITHUB_ENV if: ${{ steps.build.outcome == 'success' && always() }} - - name: Typing + - name: Typing + pylint uses: pre-commit/action@v2.0.3 with: extra_args: --hook-stage manual --all-files diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1893f57fc09c1..4d83803975ff4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -63,6 +63,8 @@ repos: rev: v2.15.5 hooks: - id: pylint + language: system + stages: [manual] - repo: https://github.com/PyCQA/isort rev: 5.10.1 hooks: diff --git a/environment.yml b/environment.yml index f6ef6367800bd..2e1ebba4afdf6 100644 --- a/environment.yml +++ b/environment.yml @@ -89,6 +89,7 @@ dependencies: - flake8-bugbear=22.7.1 # used by flake8, find likely bugs - isort>=5.2.1 # check that imports are in the right order - mypy=0.981 + - pylint=2.15.5 - pre-commit>=2.15.0 - pycodestyle # used by flake8 - pyupgrade diff --git a/pyproject.toml b/pyproject.toml index 397f74ddab71a..0af6965ff2d60 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,8 +59,10 @@ exclude = ''' max-line-length = 88 disable = [ "abstract-class-instantiated", + "c-extension-no-member", "import-error", "invalid-repr-returned", + "invalid-sequence-index", "invalid-unary-operand-type", "no-member", "no-name-in-module", @@ -148,6 +150,7 @@ disable = [ "invalid-overridden-method", "keyword-arg-before-vararg", "method-cache-max-size-none", + "missing-timeout", "non-parent-init-called", "overridden-final-method", "pointless-statement", diff --git a/requirements-dev.txt b/requirements-dev.txt index 5e98113625374..16aaffefeb6ed 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -68,6 +68,7 @@ flake8==5.0.4 flake8-bugbear==22.7.1 isort>=5.2.1 mypy==0.981 +pylint==2.15.5 pre-commit>=2.15.0 pycodestyle pyupgrade From 1b744e781d12542cdcdaed155b3c8e79b8ae3527 Mon Sep 17 00:00:00 2001 From: MarcoGorelli <> Date: Sat, 5 Nov 2022 09:33:44 +0000 Subject: [PATCH 2/2] undo language: system --- .pre-commit-config.yaml | 1 - environment.yml | 1 - pyproject.toml | 3 --- requirements-dev.txt | 1 - 4 files changed, 6 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 4d83803975ff4..6aa1f5659365f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -63,7 +63,6 @@ repos: rev: v2.15.5 hooks: - id: pylint - language: system stages: [manual] - repo: https://github.com/PyCQA/isort rev: 5.10.1 diff --git a/environment.yml b/environment.yml index 2e1ebba4afdf6..f6ef6367800bd 100644 --- a/environment.yml +++ b/environment.yml @@ -89,7 +89,6 @@ dependencies: - flake8-bugbear=22.7.1 # used by flake8, find likely bugs - isort>=5.2.1 # check that imports are in the right order - mypy=0.981 - - pylint=2.15.5 - pre-commit>=2.15.0 - pycodestyle # used by flake8 - pyupgrade diff --git a/pyproject.toml b/pyproject.toml index 0af6965ff2d60..397f74ddab71a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,10 +59,8 @@ exclude = ''' max-line-length = 88 disable = [ "abstract-class-instantiated", - "c-extension-no-member", "import-error", "invalid-repr-returned", - "invalid-sequence-index", "invalid-unary-operand-type", "no-member", "no-name-in-module", @@ -150,7 +148,6 @@ disable = [ "invalid-overridden-method", "keyword-arg-before-vararg", "method-cache-max-size-none", - "missing-timeout", "non-parent-init-called", "overridden-final-method", "pointless-statement", diff --git a/requirements-dev.txt b/requirements-dev.txt index 16aaffefeb6ed..5e98113625374 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -68,7 +68,6 @@ flake8==5.0.4 flake8-bugbear==22.7.1 isort>=5.2.1 mypy==0.981 -pylint==2.15.5 pre-commit>=2.15.0 pycodestyle pyupgrade