-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
63 lines (59 loc) · 1.92 KB
/
.pre-commit-config.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
repos:
- repo: https://github.com/psf/black
rev: 22.3.0
hooks:
- id: black
language_version: python3.9
args: ["--safe"]
- repo: https://github.com/PyCQA/isort
rev: 5.11.5
hooks:
- id: isort
args: ["--profile", "black"]
language_version: python3.9
#- repo: https://github.com/PyCQA/pylint
# rev: pylint-2.6.0
# Using local pylint to find project packages
# https://pre-commit.com/#repository-local-hooks
- repo: local
hooks:
- id: pylint
name: pylint # added for local repo option
entry: pylint # added for local repo option
# This is used for remote repo
#language_version: python3.9
language: python
types: [python]
args: [
#"--init-hook=\"from pylint.config import find_pylintrc; import os, sys; sys.path.append(os.path.dirname(find_pylintrc()))\""
# # E501 let black handle all line length decisions
# # W503 black conflicts with "line break before operator" rule
# # E203 black conflicts with "whitespace before ':'" rule
# "--ignore=E501,W503,E203",
]
- repo: https://github.com/PyCQA/pydocstyle
rev: 6.1.1
hooks:
- id: pydocstyle
language_version: python3.9
# args: [
# # Check for docstring presence only
# "--select=D1",
# # Don't require docstrings for tests and third party files
# '--match=(?!test).*\.py',
# ]
args: [
"--convention=google",
]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.8.0
hooks:
- id: mypy
additional_dependencies:
- "pydantic"
- "pydantic-settings"
- "types-requests"
- "types-pytz"
language_version: python3.9
#args are defined in mypy.ini
#args: ["--no-strict-optional", "--ignore-missing-imports"]