Skip to content

Commit a45c235

Browse files
CI: Try out pre-commit.ci again (#54218)
* CI: Try out pre-commit.ci again * Test CI autofix * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * turn autofix off --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent c6353c4 commit a45c235

File tree

3 files changed

+6
-62
lines changed

3 files changed

+6
-62
lines changed

.github/workflows/autoupdate-pre-commit-config.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/workflows/code-checks.yml

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -17,28 +17,8 @@ env:
1717
permissions:
1818
contents: read
1919

20+
# pre-commit run by https://pre-commit.ci/
2021
jobs:
21-
pre_commit:
22-
name: pre-commit
23-
runs-on: ubuntu-22.04
24-
concurrency:
25-
# https://github.community/t/concurrecy-not-work-for-push/183068/7
26-
group: ${{ github.event_name == 'push' && github.run_number || github.ref }}-pre-commit
27-
cancel-in-progress: true
28-
steps:
29-
- name: Checkout
30-
uses: actions/checkout@v3
31-
32-
- name: Install Python
33-
uses: actions/setup-python@v4
34-
with:
35-
python-version: '3.9'
36-
37-
- name: Run pre-commit
38-
uses: pre-commit/[email protected]
39-
with:
40-
extra_args: --verbose --all-files
41-
4222
docstring_typing_manual_hooks:
4323
name: Docstring validation, typing, and other manual pre-commit hooks
4424
runs-on: ubuntu-22.04

.pre-commit-config.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ default_stages: [
1414
]
1515
ci:
1616
autofix_prs: false
17+
autoupdate_schedule: monthly
18+
# manual stage hooks
19+
skip: [pylint, pyright, mypy, autotyping]
1720
repos:
1821
- repo: https://github.com/hauntsaninja/black-pre-commit-mirror
1922
# black compiled with mypyc
@@ -136,7 +139,7 @@ repos:
136139
stages: [manual]
137140
additional_dependencies: &pyright_dependencies
138141
139-
- id: pyright_reportGeneralTypeIssues
142+
- id: pyright
140143
# note: assumes python env is setup and activated
141144
name: pyright reportGeneralTypeIssues
142145
entry: pyright --skipunannotated -p pyright_reportGeneralTypeIssues.json --level warning
@@ -153,7 +156,7 @@ repos:
153156
pass_filenames: false
154157
types: [python]
155158
stages: [manual]
156-
- id: stubtest
159+
- id: mypy
157160
# note: assumes python env is setup and activated
158161
# note: requires pandas dev to be installed
159162
name: mypy (stubtest)

0 commit comments

Comments
 (0)