Skip to content

Commit 8aaa7b3

Browse files
authored
Organise pyproject.toml (alisw#1031)
Move tool section after project section. Remove black, isort. Move pyright after ruff.
1 parent 0241a35 commit 8aaa7b3

File tree

1 file changed

+34
-41
lines changed

1 file changed

+34
-41
lines changed

pyproject.toml

Lines changed: 34 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -2,47 +2,6 @@
22
requires = ["setuptools >= 61.0", "setuptools-scm>=8.0"]
33
build-backend = "setuptools.build_meta"
44

5-
[tool.setuptools.packages.find]
6-
where = ["."]
7-
include = ["machine_learning_hep*"]
8-
9-
[tool.setuptools_scm]
10-
11-
[tool.black]
12-
line-length = 120
13-
14-
[tool.isort]
15-
profile = "black"
16-
multi_line_output = 0
17-
18-
[tool.pyright]
19-
reportMissingImports = false
20-
reportUnboundVariable = false
21-
22-
[tool.ruff]
23-
line-length = 120
24-
25-
[tool.ruff.lint]
26-
extend-select = [ # in addition to defaults ["E4", "E7", "E9", "F"], see https://docs.astral.sh/ruff/rules/
27-
"A", # flake8-builtins
28-
"ARG", # flake8-unused-arguments
29-
"B", # flake8-bugbear
30-
"C4", # flake8-comprehensions
31-
"FLY", # flynt
32-
"FURB", # refurb
33-
"I", # isort
34-
"NPY", # NumPy-specific rules
35-
"PD", # pandas-vet
36-
"PL", # Pylint
37-
"RUF", # Ruff-specific rules
38-
"SIM", # flake8-simplify
39-
"UP", # pyupgrade
40-
"W", # pycodestyle Warning
41-
]
42-
ignore = [
43-
"PD901", # Avoid using the generic variable name `df` for DataFrames
44-
]
45-
465
[project]
476
name = "MachineLearningHEP"
487
dynamic = ["version"]
@@ -99,3 +58,37 @@ Repository = "https://github.com/alisw/MachineLearningHEP"
9958
[project.scripts]
10059
mlhep = "machine_learning_hep.steer_analysis:main"
10160
dl_train = "machine_learning_hep.utils.dl_train:main"
61+
62+
[tool.setuptools.packages.find]
63+
where = ["."]
64+
include = ["machine_learning_hep*"]
65+
66+
[tool.setuptools_scm]
67+
68+
[tool.ruff]
69+
line-length = 120
70+
71+
[tool.ruff.lint]
72+
extend-select = [ # in addition to defaults ["E4", "E7", "E9", "F"], see https://docs.astral.sh/ruff/rules/
73+
"A", # flake8-builtins
74+
"ARG", # flake8-unused-arguments
75+
"B", # flake8-bugbear
76+
"C4", # flake8-comprehensions
77+
"FLY", # flynt
78+
"FURB", # refurb
79+
"I", # isort
80+
"NPY", # NumPy-specific rules
81+
"PD", # pandas-vet
82+
"PL", # Pylint
83+
"RUF", # Ruff-specific rules
84+
"SIM", # flake8-simplify
85+
"UP", # pyupgrade
86+
"W", # pycodestyle Warning
87+
]
88+
ignore = [
89+
"PD901", # Avoid using the generic variable name `df` for DataFrames
90+
]
91+
92+
[tool.pyright]
93+
reportMissingImports = false
94+
reportUnboundVariable = false

0 commit comments

Comments
 (0)