forked from narwhals-dev/narwhals
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
41 lines (41 loc) · 1.14 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
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: 'v0.5.1'
hooks:
# Run the formatter.
- id: ruff-format
# Run the linter.
- id: ruff
args: [--fix]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v1.10.1'
hooks:
- id: mypy
additional_dependencies: ['polars==1.1.0', 'pytest==8.0.1']
exclude: utils|tpch
- repo: https://github.com/codespell-project/codespell
rev: 'v2.3.0'
hooks:
- id: codespell
files: \.(py|rst|md)$
args: [--ignore-words-list=ser]
exclude: ^docs/api-completeness.md$
- repo: local
hooks:
- id: check-api-reference
name: check-api-reference
pass_filenames: false
entry: python -m utils.check_api_reference
language: python
additional_dependencies: [polars]
- id: imports-are-banned
name: import are banned (use `get_pandas` instead of `import pandas`)
entry: (?<!>>> )import (pandas|polars|modin|cudf|pyarrow)
language: pygrep
files: ^narwhals/
exclude: ^narwhals/dependencies\.py
- repo: https://github.com/kynan/nbstripout
rev: 0.7.1
hooks:
- id: nbstripout