-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
71 lines (64 loc) · 1.86 KB
/
.pre-commit-config.yaml
File metadata and controls
71 lines (64 loc) · 1.86 KB
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
64
65
66
67
68
69
70
71
# Install the pre-commit hooks below with
# 'pre-commit install'
# Auto-update the version of the hooks with
# 'pre-commit autoupdate'
# Run the hooks on all files with
# 'pre-commit run --all'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c # frozen: v6.0.0
hooks:
- id: check-ast
- id: check-merge-conflict
- id: check-toml
- id: check-yaml
exclude: |
(?x)^(
examples/k8s/svc-acct\.yaml |
ci/k8s/indexed-job\.yaml
)$
- id: end-of-file-fixer
# only include python files
files: \.py$
- id: debug-statements
# only include python files
files: \.py$
- id: trailing-whitespace
# only include python files
files: \.py$
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: 0470f7c8a653e950f7cc5a653204ceb3fde4c02a # frozen: v0.15.1
hooks:
- id: ruff
- repo: https://github.com/facebook/pyrefly-pre-commit
rev: b12404a8c8109c337e78bae52ed68b42f2941f39 # frozen: v0.58.0
hooks:
- id: pyrefly-check
name: Pyrefly (type checking)
pass_filenames: false
additional_dependencies:
- absl-py==2.4.0
- types-requests~=2.32.0
- numpy~=2.4.0
- ml_dtypes~=0.5.0
- opt-einsum~=3.4.0
- scipy-stubs
- --pre
- --extra-index-url
- https://us-python.pkg.dev/ml-oss-artifacts-published/jax/simple/
- jaxlib
- repo: https://github.com/mwouts/jupytext
rev: 8ed836db64ad5d304f2315e6bfd9049c9142e190 # frozen: v1.16.4
hooks:
- id: jupytext
files: docs/
args: [--sync]
- repo: local
hooks:
- id: check-copyright
name: check copyright notice
entry: python3 build/check_copyright.py
language: python
additional_dependencies: [google-re2]
files: \.(py|cc|h|c|cu|bzl)$|BUILD
exclude: ^(jax/_src/third_party/|tests/third_party/)