-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
220 lines (197 loc) · 4.77 KB
/
pyproject.toml
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.version]
path = "cpymadtools/_version.py"
[tool.hatch.build.targets.sdist]
exclude = [
"/.github",
"/docs",
"/tests",
]
[tool.hatch.build.targets.wheel]
packages = ["cpymadtools"]
[project]
name = "cpymadtools"
readme = "README.md"
description = "Lightweigth pythonic wrapper around cpymad, extracted from pyhdtoolkit"
authors = [
{name = "Felix Soubelet", email = "felix.soubelet@cern.ch"},
]
license = "Apache-2.0"
dynamic = ["version"]
requires-python = ">=3.8"
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Programming Language :: Python",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: Implementation :: CPython",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Physics",
"Topic :: Scientific/Engineering :: Visualization",
"Topic :: Utilities",
]
dependencies = [
"cpymad >= 1.9",
"numpy >= 1.21",
"pandas >= 1.4",
"matplotlib >=3.3",
"scipy >= 1.6",
"tfs-pandas >= 3.2",
"optics-functions >= 0.1",
]
[project.optional-dependencies]
test = [
"pytest >= 6.0",
"pytest-cov >= 3.0",
"pytest-xdist >= 2.5",
"flaky >= 3.5",
"pytest-randomly >= 3.3",
"coverage[toml] >= 5.2",
]
dev = [
"black >= 22.1",
"isort >= 5.10",
"pylint >= 2.4",
]
docs = [
"Sphinx >= 4.4",
"sphinx-rtd-theme >= 1.0",
"sphinx-issues >= 3.0",
"sphinx_copybutton < 1.0",
"sphinxcontrib-bibtex >= 2.4",
"sphinx-panels < 1.0",
"sphinx-gallery < 1.0",
"sphinx-prompt >= 1.5",
]
[project.urls]
homepage = "https://github.com/beamopticsanalysis/cpymadtools"
repository = "https://github.com/beamopticsanalysis/cpymadtools"
documentation = "https://beamopticsanalysis.github.io/cpymadtools/"
changelog = "https://beamopticsanalysis.github.io/cpymadtools/release.html"
# ----- Testing Configuration ----- #
[tool.pytest.ini_options]
addopts = "--cov-report=xml --cov-report term-missing --cov-config=pyproject.toml --cov=cpymadtools"
testpaths = ["tests"]
[tool.coverage.run]
source = ["cpymadtools/"]
[tool.coverage.report]
ignore_errors = true
precision = 2
# ----- Dev Tools Configuration ----- #
[tool.isort]
atomic = true
ensure_newline_before_comments = true
filter_files = true
force_grid_wrap = 0
force_single_line = false
include_trailing_comma = true
known_first_party = "pyhdtoolkit"
known_third_party = "pytest"
line_length = 110
lines_between_types = 1
multi_line_output = 3
use_parentheses = true
profile = "black"
[tool.black]
line-length = 120
include = '\.pyi?$'
exclude = '''
/(
\.eggs
| \.git
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| _build
| buck-out
| build
| dist
| tests/.*/setup.py
)/
'''
[tool.mypy]
pretty = true
strict_optional = false
show_error_codes = true
warn_redundant_casts = true
ignore_missing_imports = true
follow_imports = "skip"
[tool.pylint]
[tool.pylint.master]
jobs="1" # Auto-detect the number of processors
ignore-patterns='''
\.eggs
|\.git
|build
|dist
|conf.py
'''
persistent="no"
load-plugins=""
limit-inference-results="100"
suggestion-mode="yes"
unsafe-load-any-extension="no"
extension-pkg-whitelist=""
exit-zero="no"
from-stdin="no"
[tool.pylint.messages_control]
disable = [
"attribute-defined-outside-init",
"bad-continuation",
"expression-not-assigned",
"invalid-name",
"import-error",
"logging-format-interpolation",
"protected-access",
"too-few-public-methods",
"too-many-instance-attributes",
"format", # handled by black
]
[tool.pylint.reports]
output-format="text"
msg-template="{path}:{line}:{column}: Pylint: {msg}. [{msg_id}: {symbol}]"
[tool.pylint.basic]
argument-naming-style="snake_case"
attr-naming-style="snake_case"
class-attribute-naming-style="snake_case"
class-naming-style="PascalCase"
const-naming-style="UPPER_CASE"
function-naming-style="snake_case"
inlinevar-naming-style="snake_case"
method-naming-style="snake_case"
module-naming-style="snake_case"
variable-naming-style="snake_case"
[tool.pylint.design]
max-args="10"
max-attributes="10"
max-locals="15"
max-public-methods="20"
max-returns="5"
[tool.pylint.'SIMILARITIES']
ignore-comments=['yes']
ignore-docstrings=['yes']
ignore-imports=['no']
min-similarity-lines=4
[tool.interrogate]
ignore-init-method = true
ignore-init-module = true
ignore-magic = false
ignore-semiprivate = false
ignore-private = false
ignore-property-decorators = false
ignore-module = false
fail-under = 95
exclude = ["tests"]
ignore-regex = []
verbose = 2
quiet = false
whitelist-regex = []
color = true