|
8 | 8 | skip: [ |
9 | 9 | 'pip-audit', |
10 | 10 | 'yesqa', |
| 11 | + 'creosote', |
11 | 12 | 'no-commit-to-branch', |
12 | 13 | # 'hadolint-docker', |
13 | 14 | 'docker-compose-check', |
@@ -42,17 +43,15 @@ repos: |
42 | 43 | 'PYSEC-2022-42969', # https://github.com/pytest-dev/pytest/issues/10392 |
43 | 44 | '--ignore-vuln', |
44 | 45 | 'PYSEC-2023-73', # https://github.com/RedisLabs/redisraft/issues/608 |
45 | | - '--ignore-vuln', |
46 | | - 'PYSEC-2023-101', # https://github.com/pytest-dev/pytest-selenium/issues/310 |
47 | 46 | ] |
48 | 47 | files: ^requirements/.*\.txt$ |
49 | 48 | - repo: https://github.com/asottile/pyupgrade |
50 | 49 | rev: v3.15.0 |
51 | 50 | hooks: |
52 | 51 | - id: pyupgrade |
53 | | - args: ['--keep-runtime-typing', '--py310-plus'] |
| 52 | + args: ['--keep-runtime-typing', '--py311-plus'] |
54 | 53 | - repo: https://github.com/astral-sh/ruff-pre-commit |
55 | | - rev: v0.0.292 |
| 54 | + rev: v0.1.6 |
56 | 55 | hooks: |
57 | 56 | - id: ruff |
58 | 57 | args: ['--fix', '--exit-non-zero-on-fix'] |
|
98 | 97 | additional_dependencies: |
99 | 98 | - tomli |
100 | 99 | - repo: https://github.com/psf/black |
101 | | - rev: 23.9.1 |
| 100 | + rev: 23.11.0 |
102 | 101 | hooks: |
103 | 102 | - id: black |
104 | 103 | # Mypy is temporarily disabled until the SQLAlchemy 2.0 migration is complete |
@@ -146,6 +145,27 @@ repos: |
146 | 145 | args: ['-c', 'pyproject.toml'] |
147 | 146 | additional_dependencies: |
148 | 147 | - 'bandit[toml]' |
| 148 | + - repo: https://github.com/fredrikaverpil/creosote |
| 149 | + rev: v3.0.0 |
| 150 | + hooks: |
| 151 | + - id: creosote |
| 152 | + args: |
| 153 | + - --venv=.venv |
| 154 | + - --path=funnel |
| 155 | + - --path=tests |
| 156 | + - --path=migrations/versions |
| 157 | + - --deps-file=requirements/base.in |
| 158 | + - --exclude-dep=argon2-cffi # Optional dep for passlib |
| 159 | + - --exclude-dep=bcrypt # Optional dep for passlib |
| 160 | + - --exclude-dep=greenlet # Optional dep for SQLAlchemy's asyncio support |
| 161 | + - --exclude-dep=gunicorn # Not imported, used as server |
| 162 | + - --exclude-dep=linkify-it-py # Optional dep for markdown-it-py |
| 163 | + - --exclude-dep=psycopg # Optional dep for SQLAlchemy |
| 164 | + - --exclude-dep=rq-dashboard # Creosote fails to recognise the import |
| 165 | + - --exclude-dep=tzdata # Data-only dep, therefore no import statement |
| 166 | + - --exclude-dep=urllib3 # Required to silence a pip-audit warning |
| 167 | + - --exclude-dep=wtforms-sqlalchemy # Temp dep on an unreleased git branch |
| 168 | + |
149 | 169 | - repo: https://github.com/pre-commit/pre-commit-hooks |
150 | 170 | rev: v4.5.0 |
151 | 171 | hooks: |
@@ -188,7 +208,7 @@ repos: |
188 | 208 | - id: forbid-tabs |
189 | 209 | - id: remove-tabs |
190 | 210 | - repo: https://github.com/pre-commit/mirrors-prettier |
191 | | - rev: v3.0.3 |
| 211 | + rev: v3.1.0 |
192 | 212 | hooks: |
193 | 213 | - id: prettier |
194 | 214 | args: |
|
0 commit comments