Skip to content

Commit

Permalink
Merge branch 'pylint-dev:main' into per_directory_configs
Browse files Browse the repository at this point in the history
  • Loading branch information
0nf committed Mar 29, 2024
2 parents 5fd935c + 10a093e commit b0b9139
Show file tree
Hide file tree
Showing 26 changed files with 167 additions and 56 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
timeout-minutes: 10
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
with:
# `towncrier check` runs `git diff --name-only origin/main...`, which
# needs a non-shallow clone.
Expand All @@ -41,7 +41,7 @@ jobs:
$GITHUB_OUTPUT
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key: >-
Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
pre-commit-key: ${{ steps.generate-pre-commit-key.outputs.key }}
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -49,7 +49,7 @@ jobs:
$GITHUB_OUTPUT
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key: >-
Expand All @@ -71,7 +71,7 @@ jobs:
hashFiles('.pre-commit-config.yaml') }}" >> $GITHUB_OUTPUT
- name: Restore pre-commit environment
id: cache-precommit
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: >-
Expand All @@ -89,7 +89,7 @@ jobs:
needs: prepare-base
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -98,7 +98,7 @@ jobs:
check-latest: true
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
fail-on-cache-miss: true
Expand All @@ -107,7 +107,7 @@ jobs:
needs.prepare-base.outputs.python-key }}
- name: Restore pre-commit environment
id: cache-precommit
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: ${{ env.PRE_COMMIT_CACHE }}
fail-on-cache-miss: true
Expand All @@ -130,7 +130,7 @@ jobs:
needs: prepare-base
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -139,7 +139,7 @@ jobs:
check-latest: true
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
fail-on-cache-miss: true
Expand All @@ -158,7 +158,7 @@ jobs:
needs: prepare-base
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -167,7 +167,7 @@ jobs:
check-latest: true
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
fail-on-cache-miss: true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/primer-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
python-key: ${{ steps.generate-python-key.outputs.key }}
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -51,7 +51,7 @@ jobs:
$GITHUB_OUTPUT
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key: >-
Expand All @@ -75,7 +75,7 @@ jobs:
python-version: [3.8, 3.9, "3.10", "3.11", "3.12"]
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -84,7 +84,7 @@ jobs:
check-latest: true
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
fail-on-cache-miss: true
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/primer_comment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -41,7 +41,7 @@ jobs:
# Restore cached Python environment
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/primer_run_main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
batchIdx: [0, 1, 2, 3]
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -45,7 +45,7 @@ jobs:
# Create a re-usable virtual environment
- name: Create Python virtual environment cache
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key:
Expand All @@ -71,7 +71,7 @@ jobs:
echo "commitstring=$output" >> $GITHUB_OUTPUT
- name: Restore projects cache
id: cache-projects
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: tests/.pylint_primer_tests/
key: >-
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/primer_run_pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
batchIdx: [0, 1, 2, 3]
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
with:
fetch-depth: 0
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -56,7 +56,7 @@ jobs:
# Restore cached Python environment
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key:
Expand Down Expand Up @@ -140,7 +140,7 @@ jobs:
echo "commitstring=$output" >> $GITHUB_OUTPUT
- name: Restore projects cache
id: cache-projects
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: tests/.pylint_primer_tests/
key: >-
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
url: https://pypi.org/project/pylint/
steps:
- name: Check out code from Github
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.0.0
Expand Down
26 changes: 13 additions & 13 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
python-key: ${{ steps.generate-python-key.outputs.key }}
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -52,7 +52,7 @@ jobs:
$GITHUB_OUTPUT
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key: >-
Expand Down Expand Up @@ -88,7 +88,7 @@ jobs:
needs: tests-linux
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python 3.12
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -97,15 +97,15 @@ jobs:
check-latest: true
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
fail-on-cache-miss: true
key:
${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
needs.tests-linux.outputs.python-key }}
- name: Download all coverage artifacts
uses: actions/download-artifact@v4.1.2
uses: actions/download-artifact@v4.1.4
- name: Combine coverage results
run: |
. venv/bin/activate
Expand All @@ -128,7 +128,7 @@ jobs:
python-version: ["3.12"]
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -137,7 +137,7 @@ jobs:
check-latest: true
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
fail-on-cache-miss: true
Expand Down Expand Up @@ -182,7 +182,7 @@ jobs:
# Workaround to set correct temp directory on Windows
# https://github.com/actions/virtual-environments/issues/712
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -197,7 +197,7 @@ jobs:
}}" >> $env:GITHUB_OUTPUT
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key: >-
Expand Down Expand Up @@ -228,7 +228,7 @@ jobs:
python-version: [3.8]
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -243,7 +243,7 @@ jobs:
}}" >> $GITHUB_OUTPUT
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key: >-
Expand Down Expand Up @@ -272,7 +272,7 @@ jobs:
python-version: ["pypy-3.8", "pypy-3.9"]
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4.1.1
uses: actions/checkout@v4.1.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.0.0
Expand All @@ -287,7 +287,7 @@ jobs:
}}" >> $GITHUB_OUTPUT
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v4.0.0
uses: actions/cache@v4.0.2
with:
path: venv
key: >-
Expand Down
16 changes: 12 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ repos:
doc/data/messages/m/missing-final-newline/bad/crlf.py
)$
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.2.2"
rev: "v0.3.2"
hooks:
- id: ruff
args: ["--fix"]
Expand Down Expand Up @@ -87,7 +87,15 @@ repos:
entry: pylint
language: system
types: [python]
args: ["-rn", "-sn", "--rcfile=pylintrc", "--fail-on=I", "--spelling-dict=en"]
args:
[
"-rn",
"-sn",
"--rcfile=pylintrc",
"--fail-on=I",
"--spelling-dict=en",
"--output-format=github",
]
exclude: tests(/\w*)*/functional/|tests/input|tests(/\w*)*data/|doc/
stages: [manual]
- id: sphinx-generated-doc
Expand All @@ -112,7 +120,7 @@ repos:
files: ^(doc/(.*/)*.*\.rst)
additional_dependencies: [Sphinx==5.0.1]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.8.0
rev: v1.9.0
hooks:
- id: mypy
name: mypy
Expand Down Expand Up @@ -158,7 +166,7 @@ repos:
setup.cfg
)$
- repo: https://github.com/PyCQA/bandit
rev: 1.7.7
rev: 1.7.8
hooks:
- id: bandit
args: ["-r", "-lll"]
Expand Down

0 comments on commit b0b9139

Please sign in to comment.