Skip to content

Commit 11e36d7

Browse files
[pre-commit.ci] pre-commit autoupdate (#268)
* [pre-commit.ci] pre-commit autoupdate updates: - [github.com/astral-sh/ruff-pre-commit: v0.4.4 → v0.5.0](astral-sh/ruff-pre-commit@v0.4.4...v0.5.0) - [github.com/adamchainz/blacken-docs: 1.16.0 → 1.18.0](adamchainz/blacken-docs@1.16.0...1.18.0) - [github.com/tox-dev/pyproject-fmt: 2.0.4 → 2.1.3](tox-dev/pyproject-fmt@2.0.4...2.1.3) * Update Pyproject formatting * Reformat remove 3.9 upstream tests * Add new Zarr requirement * More new Zarr requirements * Gahh, even more new Zarr requirements * Remove Zarr from upstream tests and pin to less than 3 * Fully remove upstream Zarr line --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Alex Kerney <[email protected]>
1 parent 421cc08 commit 11e36d7

File tree

3 files changed

+37
-50
lines changed

3 files changed

+37
-50
lines changed

.github/workflows/main.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
runs-on: ubuntu-latest
1313
strategy:
1414
matrix:
15-
python-version: ["3.9", "3.10", "3.11", "3.12"]
15+
python-version: ["3.10", "3.11", "3.12"]
1616
pydantic-version: ["<2", ">=2"]
1717
steps:
1818
- uses: actions/checkout@v4
@@ -56,7 +56,7 @@ jobs:
5656
runs-on: ubuntu-latest
5757
strategy:
5858
matrix:
59-
python-version: ["3.9", "3.10", "3.11", "3.12"]
59+
python-version: ["3.10", "3.11", "3.12"]
6060
steps:
6161
- uses: actions/checkout@v4
6262

.pre-commit-config.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ repos:
1010
- id: double-quote-string-fixer
1111

1212
- repo: https://github.com/astral-sh/ruff-pre-commit
13-
rev: "v0.4.4"
13+
rev: "v0.5.0"
1414
hooks:
1515
- id: ruff
1616
args: [--fix, --exit-non-zero-on-fix]
@@ -23,7 +23,7 @@ repos:
2323
- mdformat-myst
2424

2525
- repo: https://github.com/adamchainz/blacken-docs
26-
rev: "1.16.0"
26+
rev: "1.18.0"
2727
hooks:
2828
- id: blacken-docs
2929
additional_dependencies:
@@ -43,7 +43,7 @@ repos:
4343
- markdown # managed by mdformat
4444

4545
- repo: https://github.com/tox-dev/pyproject-fmt
46-
rev: "2.0.4"
46+
rev: "2.1.3"
4747
hooks:
4848
- id: pyproject-fmt
4949

pyproject.toml

+32-45
Original file line numberDiff line numberDiff line change
@@ -65,58 +65,57 @@ skip-string-normalization = true
6565
[tool.ruff]
6666
line-length = 100
6767

68-
[tool.ruff.lint]
69-
select = [
68+
lint.select = [
7069
"B", # flake8-bugbear
71-
"C",
72-
'D', # pydocstyle
73-
"E", # pycodestyle
74-
"F", # Pyflakes
75-
"I", # isort
76-
"W", # pycodestyle
7770
# "T4",
7871
"B9",
72+
"C",
73+
"D", # pydocstyle
74+
"E", # pycodestyle
75+
"F", # Pyflakes
76+
"I", # isort
77+
"W", # pycodestyle
7978
]
80-
ignore = [
79+
lint.ignore = [
80+
"C901",
8181
"D100", # Missing docstring in public module
82-
"D107", # Missing docstring in `__init__`
8382
"D104", # Missing docstring in public package
8483
"D105", # Missing docstring in magic method
84+
"D107", # Missing docstring in `__init__`
85+
"E402",
8586
# "E203",
8687
# "E266",
8788
"E501",
8889
# "W503",
8990
"E722",
90-
"E402",
91-
"C901",
9291
]
93-
exclude = [
94-
"tests/",
92+
lint.exclude = [
9593
"docs/",
94+
"tests/",
9695
]
97-
98-
[tool.ruff.lint.per-file-ignores]
99-
"tests/*" = [
96+
lint.per-file-ignores."docs/*" = [
97+
"D101", # missing docstring in public class
98+
"D102", # missing docstring in public method
99+
"D103", # missing docstring in public function
100+
]
101+
lint.per-file-ignores."tests/*" = [
100102
"D103", # Missing docstring in public function
101103
"D205", # blank line between summary and description
102104
"D415", # first line should end with punctuation
103105
]
104-
"docs/*" = [
105-
"D101", # missing docstring in public class
106-
"D102", # missing docstring in public method
107-
"D103", # missing docstring in public function
106+
# Allow fastapi.Depends and other dependency injection style function arguments
107+
lint.flake8-bugbear.extend-immutable-calls = [
108+
"fastapi.Depends",
109+
"fastapi.Path",
110+
"fastapi.Query",
108111
]
109-
110-
[tool.ruff.lint.mccabe]
111-
# Unlike Flake8, default to a complexity level of 10.
112-
max-complexity = 18
113-
114-
[tool.ruff.lint.isort]
115-
combine-as-imports = true
116-
known-first-party = [
112+
lint.flake8-quotes.docstring-quotes = "double"
113+
lint.flake8-quotes.inline-quotes = "single"
114+
lint.isort.combine-as-imports = true
115+
lint.isort.known-first-party = [
117116
"xpublish",
118117
]
119-
known-third-party = [
118+
lint.isort.known-third-party = [
120119
"cachey",
121120
"dask",
122121
"fastapi",
@@ -134,22 +133,10 @@ known-third-party = [
134133
"xarray",
135134
"zarr",
136135
]
137-
138-
[tool.ruff.lint.pydocstyle]
136+
# Unlike Flake8, default to a complexity level of 10.
137+
lint.mccabe.max-complexity = 18
139138
# Use Google style docstrings
140-
convention = "google"
141-
142-
[tool.ruff.lint.flake8-quotes]
143-
inline-quotes = "single"
144-
docstring-quotes = "double"
145-
146-
[tool.ruff.lint.flake8-bugbear]
147-
# Allow fastapi.Depends and other dependency injection style function arguments
148-
extend-immutable-calls = [
149-
"fastapi.Depends",
150-
"fastapi.Query",
151-
"fastapi.Path",
152-
]
139+
lint.pydocstyle.convention = "google"
153140

154141
[tool.pytest.ini_options]
155142
log_cli = true

0 commit comments

Comments
 (0)