Skip to content

Commit 8c2a823

Browse files
authored
Merge pull request #8188 from python-pillow/pre-commit-ci-update-config
[pre-commit.ci] pre-commit autoupdate
2 parents 06cad14 + c359bd2 commit 8c2a823

File tree

2 files changed

+62
-55
lines changed

2 files changed

+62
-55
lines changed

.pre-commit-config.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/astral-sh/ruff-pre-commit
3-
rev: v0.4.7
3+
rev: v0.5.0
44
hooks:
55
- id: ruff
66
args: [--exit-non-zero-on-fix]
@@ -11,7 +11,7 @@ repos:
1111
- id: black
1212

1313
- repo: https://github.com/PyCQA/bandit
14-
rev: 1.7.8
14+
rev: 1.7.9
1515
hooks:
1616
- id: bandit
1717
args: [--severity-level=high]
@@ -24,7 +24,7 @@ repos:
2424
exclude: (Makefile$|\.bat$|\.cmake$|\.eps$|\.fits$|\.gd$|\.opt$)
2525

2626
- repo: https://github.com/pre-commit/mirrors-clang-format
27-
rev: v18.1.5
27+
rev: v18.1.8
2828
hooks:
2929
- id: clang-format
3030
types: [c]
@@ -50,7 +50,7 @@ repos:
5050
exclude: ^.github/.*TEMPLATE|^Tests/(fonts|images)/
5151

5252
- repo: https://github.com/python-jsonschema/check-jsonschema
53-
rev: 0.28.4
53+
rev: 0.28.6
5454
hooks:
5555
- id: check-github-workflows
5656
- id: check-readthedocs
@@ -62,7 +62,7 @@ repos:
6262
- id: sphinx-lint
6363

6464
- repo: https://github.com/tox-dev/pyproject-fmt
65-
rev: 1.8.0
65+
rev: 2.1.3
6666
hooks:
6767
- id: pyproject-fmt
6868

pyproject.toml

Lines changed: 57 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,10 @@ readme = "README.md"
1414
keywords = [
1515
"Imaging",
1616
]
17-
license = {text = "HPND"}
18-
authors = [{name = "Jeffrey A. Clark", email = "[email protected]"}]
17+
license = { text = "HPND" }
18+
authors = [
19+
{ name = "Jeffrey A. Clark", email = "[email protected]" },
20+
]
1921
requires-python = ">=3.8"
2022
classifiers = [
2123
"Development Status :: 6 - Mature",
@@ -38,22 +40,21 @@ classifiers = [
3840
dynamic = [
3941
"version",
4042
]
41-
[project.optional-dependencies]
42-
docs = [
43+
optional-dependencies.docs = [
4344
"furo",
4445
"olefile",
4546
"sphinx>=7.3",
4647
"sphinx-copybutton",
4748
"sphinx-inline-tabs",
4849
"sphinxext-opengraph",
4950
]
50-
fpx = [
51+
optional-dependencies.fpx = [
5152
"olefile",
5253
]
53-
mic = [
54+
optional-dependencies.mic = [
5455
"olefile",
5556
]
56-
tests = [
57+
optional-dependencies.tests = [
5758
"check-manifest",
5859
"coverage",
5960
"defusedxml",
@@ -65,28 +66,29 @@ tests = [
6566
"pytest-cov",
6667
"pytest-timeout",
6768
]
68-
typing = [
69-
'typing-extensions; python_version < "3.10"',
69+
optional-dependencies.typing = [
70+
"typing-extensions; python_version<'3.10'",
7071
]
71-
xmp = [
72+
optional-dependencies.xmp = [
7273
"defusedxml",
7374
]
74-
[project.urls]
75-
Changelog = "https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst"
76-
Documentation = "https://pillow.readthedocs.io"
77-
Funding = "https://tidelift.com/subscription/pkg/pypi-pillow?utm_source=pypi-pillow&utm_medium=pypi"
78-
Homepage = "https://python-pillow.org"
79-
Mastodon = "https://fosstodon.org/@pillow"
80-
"Release notes" = "https://pillow.readthedocs.io/en/stable/releasenotes/index.html"
81-
Source = "https://github.com/python-pillow/Pillow"
75+
urls.Changelog = "https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst"
76+
urls.Documentation = "https://pillow.readthedocs.io"
77+
urls.Funding = "https://tidelift.com/subscription/pkg/pypi-pillow?utm_source=pypi-pillow&utm_medium=pypi"
78+
urls.Homepage = "https://python-pillow.org"
79+
urls.Mastodon = "https://fosstodon.org/@pillow"
80+
urls."Release notes" = "https://pillow.readthedocs.io/en/stable/releasenotes/index.html"
81+
urls.Source = "https://github.com/python-pillow/Pillow"
8282

8383
[tool.setuptools]
84-
packages = ["PIL"]
84+
packages = [
85+
"PIL",
86+
]
8587
include-package-data = true
86-
package-dir = {"" = "src"}
88+
package-dir = { "" = "src" }
8789

8890
[tool.setuptools.dynamic]
89-
version = {attr = "PIL.__version__"}
91+
version = { attr = "PIL.__version__" }
9092

9193
[tool.cibuildwheel]
9294
before-all = ".github/workflows/wheels-dependencies.sh"
@@ -98,42 +100,47 @@ test-extras = "tests"
98100
[tool.ruff]
99101
fix = true
100102

101-
[tool.ruff.lint]
102-
select = [
103-
"C4", # flake8-comprehensions
104-
"E", # pycodestyle errors
105-
"EM", # flake8-errmsg
106-
"F", # pyflakes errors
107-
"I", # isort
108-
"ISC", # flake8-implicit-str-concat
109-
"LOG", # flake8-logging
110-
"PGH", # pygrep-hooks
111-
"PYI", # flake8-pyi
103+
lint.select = [
104+
"C4", # flake8-comprehensions
105+
"E", # pycodestyle errors
106+
"EM", # flake8-errmsg
107+
"F", # pyflakes errors
108+
"I", # isort
109+
"ISC", # flake8-implicit-str-concat
110+
"LOG", # flake8-logging
111+
"PGH", # pygrep-hooks
112+
"PYI", # flake8-pyi
112113
"RUF100", # unused noqa (yesqa)
113-
"UP", # pyupgrade
114-
"W", # pycodestyle warnings
115-
"YTT", # flake8-2020
116-
]
117-
ignore = [
118-
"E203", # Whitespace before ':'
119-
"E221", # Multiple spaces before operator
120-
"E226", # Missing whitespace around arithmetic operator
121-
"E241", # Multiple spaces after ','
114+
"UP", # pyupgrade
115+
"W", # pycodestyle warnings
116+
"YTT", # flake8-2020
117+
]
118+
lint.ignore = [
119+
"E203", # Whitespace before ':'
120+
"E221", # Multiple spaces before operator
121+
"E226", # Missing whitespace around arithmetic operator
122+
"E241", # Multiple spaces after ','
122123
"PYI026", # flake8-pyi: typing.TypeAlias added in Python 3.10
123124
"PYI034", # flake8-pyi: typing.Self added in Python 3.11
124125
]
125-
126-
[tool.ruff.lint.per-file-ignores]
127-
"Tests/oss-fuzz/fuzz_font.py" = ["I002"]
128-
"Tests/oss-fuzz/fuzz_pillow.py" = ["I002"]
129-
130-
[tool.ruff.lint.isort]
131-
known-first-party = ["PIL"]
132-
required-imports = ["from __future__ import annotations"]
126+
lint.per-file-ignores."Tests/oss-fuzz/fuzz_font.py" = [
127+
"I002",
128+
]
129+
lint.per-file-ignores."Tests/oss-fuzz/fuzz_pillow.py" = [
130+
"I002",
131+
]
132+
lint.isort.known-first-party = [
133+
"PIL",
134+
]
135+
lint.isort.required-imports = [
136+
"from __future__ import annotations",
137+
]
133138

134139
[tool.pytest.ini_options]
135140
addopts = "-ra --color=yes"
136-
testpaths = ["Tests"]
141+
testpaths = [
142+
"Tests",
143+
]
137144

138145
[tool.mypy]
139146
python_version = "3.8"

0 commit comments

Comments
 (0)