Skip to content

Commit 2838ad1

Browse files
committed
🔧 Check and format pyproject.toml
* Add pyproject-fmt and validate-pyproject
1 parent f218de4 commit 2838ad1

File tree

2 files changed

+72
-46
lines changed

2 files changed

+72
-46
lines changed

.pre-commit-config.yaml

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,25 @@ repos:
88
- repo: https://github.com/pre-commit/pre-commit-hooks
99
rev: v6.0.0
1010
hooks:
11-
- id: trailing-whitespace
12-
- id: end-of-file-fixer
13-
- id: check-yaml
14-
types: [file]
15-
files: \.(yml|yaml|cff)$
1611
- id: check-added-large-files
1712
args: ['--maxkb=1024']
1813
- id: check-json
1914
types: [file] # override `types: [json]`
2015
files: \.(json|ipynb)$
16+
- id: check-toml
17+
- id: check-yaml
18+
types: [file]
19+
files: \.(yml|yaml|cff)$
20+
- id: end-of-file-fixer
21+
- id: trailing-whitespace
22+
- repo: https://github.com/tox-dev/pyproject-fmt
23+
rev: v2.7.0
24+
hooks:
25+
- id: pyproject-fmt
26+
- repo: https://github.com/abravalheri/validate-pyproject
27+
rev: v0.24.1
28+
hooks:
29+
- id: validate-pyproject
2130
- repo: https://github.com/sphinx-contrib/sphinx-lint
2231
rev: v1.0.0
2332
hooks:

pyproject.toml

Lines changed: 58 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,66 +1,83 @@
11
[project]
22
name = "jupyter-tutorial"
33
version = "24.1.0"
4-
authors = [
5-
{ name="Veit Schiele", email="veit@cusy.io" },
6-
]
74
description = "Training materials for setting up and using a research infrastructure based on Jupyter notebooks: https://cusy.io/en/seminars"
85
readme = "README.rst"
96
license = "BSD-3-Clause"
107
license-files = [ "LICENSE" ]
8+
authors = [
9+
{ name = "Veit Schiele", email = "veit@cusy.io" },
10+
]
1111
requires-python = ">=3.9"
1212
classifiers = [
13-
"Programming Language :: Python :: 3",
14-
"Operating System :: OS Independent",
13+
"Operating System :: OS Independent",
14+
"Programming Language :: Python :: 3 :: Only",
15+
"Programming Language :: Python :: 3.9",
16+
"Programming Language :: Python :: 3.10",
17+
"Programming Language :: Python :: 3.11",
18+
"Programming Language :: Python :: 3.12",
19+
"Programming Language :: Python :: 3.13",
1520
]
16-
dependencies = []
21+
dependencies = [ ]
1722

18-
[dependency-groups]
19-
docs = [
20-
"furo",
21-
"ipython",
22-
"ipywidgets",
23-
"matplotlib", # matplotlib is required for social cards
24-
"nbsphinx",
25-
"sphinx<8.2",
26-
"sphinx-inline-tabs",
27-
"sphinx-lint",
28-
"sphinx-notfound-page",
29-
"sphinx-sitemap",
30-
"sphinx_copybutton",
31-
"sphinxcontrib-svg2pdfconverter",
32-
"sphinxext.opengraph"
33-
]
23+
urls."Bug Tracker" = "https://github.com/veit/jupyter-tutorial/issues"
24+
urls."Homepage" = "https://github.com/veit/jupyter-tutorial/"
3425

26+
[dependency-groups]
3527
dev = [
36-
{ include-group = "docs" },
37-
"pre-commit",
38-
"codespell",
39-
"vale",
28+
"codespell",
29+
"pre-commit",
30+
"vale",
31+
{ include-group = "docs" },
32+
]
33+
docs = [
34+
"furo",
35+
"ipython",
36+
"ipywidgets",
37+
"matplotlib", # matplotlib is required for social cards
38+
"nbsphinx",
39+
"sphinx<8.2",
40+
"sphinx-copybutton",
41+
"sphinx-inline-tabs",
42+
"sphinx-lint",
43+
"sphinx-notfound-page",
44+
"sphinx-sitemap",
45+
"sphinxcontrib-svg2pdfconverter",
46+
"sphinxext-opengraph",
4047
]
41-
42-
[project.urls]
43-
"Homepage" = "https://github.com/veit/jupyter-tutorial/"
44-
"Bug Tracker" = "https://github.com/veit/jupyter-tutorial/issues"
4548

4649
[tool.setuptools]
47-
packages = []
50+
packages = [ ]
4851

4952
[tool.black]
5053
line-length = 79
5154

5255
[tool.isort]
53-
atomic=true
54-
force_grid_wrap=0
55-
include_trailing_comma=true
56-
lines_after_imports=2
57-
lines_between_types=1
58-
multi_line_output=3
59-
not_skip="__init__.py"
60-
use_parentheses=true
56+
atomic = true
57+
force_grid_wrap = 0
58+
include_trailing_comma = true
59+
lines_after_imports = 2
60+
lines_between_types = 1
61+
multi_line_output = 3
62+
not_skip = "__init__.py"
63+
use_parentheses = true
6164

62-
known_first_party="jupyter-tutorial-de"
63-
known_third_party=["Cython", "accounts_pb2", "accounts_pb2_grpc", "dataprep", "google", "grpc", "mpi4py", "numpy", "pandas", "pydantic", "pytest", "requests", "setuptools"]
65+
known_first_party = "jupyter-tutorial-de"
66+
known_third_party = [
67+
"Cython",
68+
"accounts_pb2",
69+
"accounts_pb2_grpc",
70+
"dataprep",
71+
"google",
72+
"grpc",
73+
"mpi4py",
74+
"numpy",
75+
"pandas",
76+
"pydantic",
77+
"pytest",
78+
"requests",
79+
"setuptools",
80+
]
6481

6582
[tool.codespell]
6683
skip = "*.html, *.ipynb, docs/hub/jupyterhub_config.py"

0 commit comments

Comments
 (0)